re PR c++/9993 (destructor not called for local object created within and returned...
authorJason Merrill <jason@redhat.com>
Mon, 17 Mar 2003 15:45:29 +0000 (10:45 -0500)
committerJason Merrill <jason@gcc.gnu.org>
Mon, 17 Mar 2003 15:45:29 +0000 (10:45 -0500)
commit35e939ae1c46ee21ad069d23f77c5e359c7c8ad1
tree5e415b4ac71c0adab0b0fb00508728fe2bc54f8f
parentf1b62339fa1f8b2021750ffe334adc3da73e8d02
re PR c++/9993 (destructor not called for local object created within and returned from infinite loop)

        PR c++/9993
        * decl.c (finish_function): Only allow the NRVO to use variables
        declared at function scope.

From-SVN: r64488
gcc/cp/ChangeLog
gcc/cp/decl.c
gcc/testsuite/g++.dg/opt/nrv6.C [new file with mode: 0644]