2010-07-27 Paolo Carlini <paolo.carlini@oracle.com>
[official-gcc/alias-decl.git] / gcc / testsuite / g++.dg / 20090107-1.C
blob7c50675dbe0d76da40f193b9490b8103491be64f
1 /* { dg-do compile } */
2 /* { dg-require-effective-target lto } */
3 /* { dg-options "-fwhopr -Wuninitialized -O1" }  */
5 template <typename T> struct Q1 { typedef int x; };
6 template <typename T> struct Q2 {
7   typename Q1<T>::x f() {
8     int k;
9     return k; /* { dg-warning "'k' is used uninitialized in this function" }  */
10   }
12 int foo() { return Q2<int>().f(); }