home
clients
know-how
products
resources
contact
home
>
resources
>
c++ coding standard
> online version
Uwyn C++ Coding Standard
Prev
Chapter 2. Naming scheme
Next
#define and Macro Names
Put #defines and macros in all upper using '_' separators.
Justification
This makes it very clear that the value is not alterable and in the case of macros, makes it clear that you are using a construct that requires care.
Some subtle errors can occur when macro names and enum labels use the same name.
Example 2-17. #define and Macro Names Example
#define MAX(a,b) blah #define IS_ERR(err) blah
Prev
Home
Next
C Function Names
Up
Code Formatting
powered by
RIFE
Copyright ©2001-2006 Uwyn bvba/sprl