[C++-sig] Wrapping #define's and anonymous enum's

William Trenker wtrenker at hotmail.com
Wed Dec 11 22:57:03 CET 2002

Many C/C++ libraries contain one or more .h/.hpp files that define various 
constants used by that library's API.

What is the prescribed method for wrapping #defines that are used to 
represent constants?

Also, how do I wrap anonymous enums?

For example, I have a project with an Constants.h file containing:

#define MSG_A 23
#define MSG_B 25
enum {Red, White, Blue = 40 };

What would the boost wrapper code for the above look like?


Tired of spam? Get advanced junk mail protection with MSN 8. 

More information about the Cplusplus-sig mailing list