[Bug c++/92106] [8/9/10 Regression] ICE with structured bindings and -Wreturn-local-addr
mpolacek at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Oct 21 18:23:00 GMT 2019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92106
--- Comment #6 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Author: mpolacek
Date: Mon Oct 21 18:22:41 2019
New Revision: 277264
URL: https://gcc.gnu.org/viewcvs?rev=277264&root=gcc&view=rev
Log:
PR c++/92106 - ICE with structured bindings and -Wreturn-local-addr.
* typeck.c (maybe_warn_about_returning_address_of_local): Avoid
recursing on null initializer and return false instead.
* g++.dg/cpp1z/decomp50.C: New test.
Added:
trunk/gcc/testsuite/g++.dg/cpp1z/decomp50.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/typeck.c
trunk/gcc/testsuite/ChangeLog
More information about the Gcc-bugs
mailing list