Boost logo

Boost :

From: Gennaro Prota (gennaro_prota_at_[hidden])
Date: 2002-12-11 18:20:30

On Wed, 11 Dec 2002 14:38:03 -0800, "Paul Mensonides"
<pmenso57_at_[hidden]> wrote:

>It easy to cause it to error though:
>#define BOOST_WORKAROUND(symbol, test) (((symbol) != 0) && 1 % ((symbol)
>test ? 1 : 0))

Ah, yes, of course! I removed division-by-zero from my mental bag of
give-me-an-error-please tools, when I discovered it just emits a
warning (removable, what's more) with Borland C++ :-)

>You could do something like this:
>#if defined(BOOST_DEVELOPER_WARNINGS) && __SUNPRO_CC > 0x530
>#pragma boost developer warning: compiler version exceeded
>// ...

Well, that's obvious. Libraries that need at least one workaround for
the latest version of a given compiler could have a separate include
file where they do a suitable test. Since it would be targeted to a
specific compiler whatever way to emit a warning or an informational
message with that compiler would be acceptable

// dynamic_bitset_config.hpp
// (probably this file would have a standard name/subdirectory)
#if ( __BORLANDC__ > 0x570) // last checked version
#pragma message Compiler version exceeded

I was just saying: "it would be nice" IF we could have this feature
somehow built-in in the macro used for the workarounds themselves.


Boost list run by bdawes at, gregod at, cpdaniel at, john at