Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2002-12-18 23:32:26


I've just checked in what I hope is the final version of boost/detail/workaround.hpp:

http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/boost/boost/boost/detail/workaround.hpp?rev=1.5&content-type=text/vnd.viewcvs-markup

The two macros defined in this file should be helpful in writing and
maintaining workaround code for broken compilers and libraries.

Usage:

    #if BOOST_WORKAROUND(BOOST_MSVC, <= 1200)
       ... workaround code here
    #endif

When BOOST_STRICT_CONFIG is defined, expands to 0. Otherwise, the
first argument must be undefined or expand to a numeric
value. The above expands to:

    (BOOST_MSVC) != 0 && (BOOST_MSVC) <= 1200

When used for workarounds on the latest known version of a
compiler, the following convention should be observed:

    #if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1301))

The version number in this case corresponds to the last version in
which the workaround was known to have been required. It only has
value as a comment unless BOOST_DETECT_OUTDATED_WORKAROUNDS is
defined, in which case a compiler warning or error will be issued
when the compiler version exceeds the argument to BOOST_TESTED_AT

-- 
                       David Abrahams
   dave_at_[hidden] * http://www.boost-consulting.com
Boost support, enhancements, training, and commercial distribution

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk