This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/986] g++ misses warning for & on temporary
- From: "raf2 at msux dot cjb dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 May 2007 07:50:18 -0000
- Subject: [Bug c++/986] g++ misses warning for & on temporary
- References: <bug-986-184@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #22 from raf2 at msux dot cjb dot net 2007-05-16 08:50 -------
Mmm... maybe I haven't explained correctly.
If you contract someone to build stairs and later he says: "As long as you
don't touch this step, everything's ok" you tell him some nasty things.
The users of our g++ programs, our boss, will tell us the same nasty things if
they know of equivalent features in our programs.
That's the point of having the compiler stopping compilations when (for
example) it detects a reference to an object that has been destroyed.
Unless someone has a useful employ of having references to objects that have
been destroyed, that is why a sample is asked.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=986