Feature Macros

Rather than checking for specific compilers directly in the code, consider using the compiler macros to set feature macros, and then use these feature macros in your code.

# define HAVE_WINDOWS_H 1

#if defined(HAVE_WINDOWS_H)
# include <windows.h>

An example of this can be found in Boost.Config.


Wiki: Home

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks