------- Comment #3 from pinskia at gcc dot gnu dot org 2006-03-13 21:50 ------- Not a bug, you are returning a reference to a local variables in: friend const T& operator << (T t, const Arg& s) { return t <<= s; }
friend const T& operator >> (T t, const Arg& s) { return t >>= s; } If you change the return type to T instead of T&, this works correctly, this is hard to warn about since >>= returns a reference to t. -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26669