Debian Codegraph @

gcc/testsuite/g++.dg/warn/Wreturn-local-addr-3.C

raw
1 // PR c++/51270
2 // { dg-options "-O2" }
3
4 const int& f(long l)
5 {
6 const int& i = l;
7 return i; // { dg-warning "address of local variable" }
8 }