Boost logo

Boost :

From: Daniel Frey (d.frey_at_[hidden])
Date: 2005-05-18 16:06:42

A new version of operators.hpp is available in the sandbox at
it contains an improved workaround for compilers that need
BOOST_NO_OPERATORS_IN_NAMESPACE. Other compilers should not be affected,
but hey, you never know :)

I'd like to ask for people to test the new version. In particular, the
following compilers set BOOST_NO_OPERATORS_IN_NAMESPACE in their
config-files (see boost/config/compiler/...) for some versions:

- GCC < v3
- Borland
- Digital Mars
- ACC (hp_acc)

If you (still) have one of these compiler with the affected versions,
please test the new operators.hpp.

Besides running the regression tests, which obviously must work, you can
try to compile the following examples with the old and the new version:

    #include <boost/operators.hpp>
    using namespace boost;
    class a:addable1<a>{
            a& operator+=(const a&){return *this;};

    int main(){

    #include <boost/operators.hpp>
    bool addable1;
    int main(){

Both examples previously failed to compile on (some of?) the compilers
that had BOOST_NO_OPERATORS_IN_NAMESPACE defined, the new version should
fix that.

Also, reviews of the patch are also welcome. One final note: The new
version will not go into 1.33.0, which is why I choose to put the new
version in the sandbox first. Once 1.33.0 is out and given that the
initial tests look positive, it will go into CVS to make sure the full
regression testing is applied and the regression test will be improved
to check for the above examples.

Out of curiousity: Will the new version (with the appropriate define
set) improve the situation for the VC7? Anyone care to check that, too?
(If it shows an improvement, I honestly have no clue why ;)

Thanks for you time.

Regards, Daniel

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