|
Boost : |
From: Peter Dimov (pdimov_at_[hidden])
Date: 2004-03-20 13:51:56
Reece Dunn wrote:
> Gennaro Prota wrote:
>
>> My goal was to choose short names, as otherwise preprocessing lines
>> easily become enormous (if nothing else, it's a boost guideline to
>> not exceed 80 characters). Note that even things like:
>>
>> #if BOOST_MSVC >= 1200
>>
>> are usually rewritten as
>>
>> #if defined(BOOST_MSVC) && BOOST_MSVC >= 1200
>>
>> just because gcc warns about the first form when using -Wundef. And
>> something like
>>
>> #if defined(BOOST_GCC_CXX_VERSION) && BOOST_GCC_CXX_VERSION >= 295
>>
>> is already 66 characters.
>
> Isn't there a BOOST_WORKAROUND macro for this?
> e.g.
> #if BOOST_WORKAROUND( BOOST_MSVC, >= 1200 )
> #if BOOST_WORKAROUND( BOOST_GCC_CXX_VERSION, >= 295 )
There is, but you still need to prefix it with defined() to
be -Wundef -clean.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk