This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/12680] C++ destructor called too early on temporary objects
- From: "gdr at integrable-solutions dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 19 Oct 2003 16:55:23 -0000
- Subject: [Bug c++/12680] C++ destructor called too early on temporary objects
- References: <20031019165033.12680.drtr@dial.pipex.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12680
------- Additional Comments From gdr at integrable-solutions dot net 2003-10-19 16:55 -------
Subject: Re: New: C++ destructor called too early on temporary objects
"drtr at dial dot pipex dot com" <gcc-bugzilla@gcc.gnu.org> writes:
| When a temporary object is created, the C++ standard requires the
| destructor to be called at the end of the enclosing block, not when
| the object goes out of scope.
This claim is false. The C++ standard requires temporary objects
destruction at the end of the full expressions that contain them.
This PR should be resolved as INVALID.
-- Gaby