Here, max is not local to function foo. It's effectively global. You can't declare a macro as a member of a C++ class or namespace. In a sense, macro names are more pervasive (read “worse”) than ...
Understand the pitfalls of using enumeration types in the domain layer of your .NET applications and the advantages of using record types instead. When working on applications, you will often need to ...