Boost logo

Boost :

From: Johan Johansson (johanj_at_[hidden])
Date: 2005-04-15 18:33:24

There may be an error in them. From

An integral constant expression can be one of the following:
2. An enumerator value.
9. The result of applying a binary operator to two integral constant 
provided that the operator is not an assignment operator, or comma operator.
Neither gcc (3.3.3) nor Metrowerks (don't remember version) seems to 
think that "enumVal1 | enumVal2" is an integral constant expression. 
This seems obvious in the case of operator| being overloaded, although 
Comeau online 4.3.3 *does* seem to swallow that without complaint, which 
greatly diminishes my expectations of being right and greatly adds to my 
confusion. However, gcc and Metrowerks seem to ban this even if 
operator| is not overloaded. I haven't found the standardese to motivate 
that yet. Someone set me straight, please!

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