Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP aC++/HP ANSI C Release Notes: Version A.06.12 > Chapter 5 Known Problems and Workarounds

Conflict Between macros.h and numeric_limits Class (min and max)

» 

Technical documentation

Complete book in PDF
» Feedback
Content starts here

 » Table of Contents

If your code includes /usr/include/macros.h, note that the min and max macros defined in macros.h conflict with the min and max functions defined in the numeric_limits class of the Standard C++ Library. The following code, for example, would generate a compiler Error 134:

numeric_limits<unsigned int>::max();

If you must use the macros.h header, try undefining the macros that conflict:

...

#include <macros.h>

#undef max

#undef min

...

Printable version
Privacy statement Using this site means you accept its terms
© 2006 Hewlett-Packard Development Company, L.P.