namespace/endl/ gcc 3.4 and 4.1.2
-
never read Stroustroup but i guess it'll look similar to this method avoiding the nasty friend functions:
http://tutorial.schornboeck.net/operatoren_ueberladung2.htm
you dont have to understand the german text, just look the code. the operator overload works nice although there is no friend function at all but .