------- Comment #4 from redi at gcc dot gnu dot org 2010-06-03 23:23 ------- Good luck with that.
Your copy constructor doesn't copy the state of the source object. Complaints like this usually only come up in unrealistic examples created to test a compiler's behaviour. There are many, many situations where copy elision is a good thing, there are very few where it's undesirable in real programs. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44409