$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Tobias Schwinger (tschwinger_at_[hidden])
Date: 2005-07-12 15:33:02
Jonathan Turkanis wrote:
> 
> The ability to accommodate these unlikely scenarios has to be balanced against
> usability. If a test for GCC with major version < 3 has to use "3000000,"
> chances are good that a test will be misspelled and a needed workaround will not
> be applied.
> 
It is possible to put an expression to calculate the 3000000 in this case into a 
macro:
     #define BOOST_VERSION(major,minor,patchlvl) \
        (major * 1000000 + minor * 1000 + patchlvl)
     #define BOOST_GCC \
        BOOST_GCC_VERSION(__GNUC__,__GNUC_MINOR__,__GNUC_PATCHLEVEL__)
Example:
     #if BOOST_WORKAROUND(BOOST_GCC,< BOOST_VERSION(3,2,3))
     // ...
     #endif
Regards,
Tobias