Boost logo

Boost :

From: Paul A. Bristow (boost_at_[hidden])
Date: 2003-09-05 06:20:27


I was surprised (but not too disappointed) to find that:

int i = 99; // Extend message using operator<<
BOOST_MESSAGE("BOOST_MESSAGE"<< ", i == " << i << endl);

fails to compile (MSVC 7.1)

message is

error C2679: binary '<<' : no operator found which takes a right-hand operand of
type 'overloaded-function' (or there is no acceptable conversion)

BOOST_MESSAGE("BOOST_MESSAGE"<< ", i == " << i); // without << endl

works fine as expected.

Is this a bug or just a feature worth documenting?

Paul

Paul A Bristow, Prizet Farmhouse, Kendal, Cumbria, LA8 8AB UK
+44 1539 561830 Mobile +44 7714 33 02 04
mailto:pbristow_at_[hidden]


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