[Bug middle-end/24786] Missing warning on questionable use of parameter to initialize static
msebor at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue May 19 21:13:23 GMT 2020
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=24786
Martin Sebor <msebor at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|FIXED |DUPLICATE
--- Comment #6 from Martin Sebor <msebor at gcc dot gnu.org> ---
Not fixed yet. There is no warning for blah2() returning the address of the
local variable. pr69433 includes a test case for the same thing:
const char* f2 () {
const char a[] = "abc";
static const char *s = a;
return s;
}
so this report can be resolved as a duplicate of that one.
*** This bug has been marked as a duplicate of bug 69433 ***
More information about the Gcc-bugs
mailing list