Prep for new warning.
authorMike Stump <mrs@apple.com>
Tue, 21 Jul 2009 19:02:55 +0000 (19:02 +0000)
committerMike Stump <mrs@apple.com>
Tue, 21 Jul 2009 19:02:55 +0000 (19:02 +0000)
llvm-svn: 76627

clang/test/CXX/class/class.local/p1.cpp

index 8a84f5d..565ddb8 100644 (file)
@@ -8,7 +8,10 @@ void f()
   extern int g();
   
   struct local {
-    int g() { return x; } // expected-error{{reference to local variable 'x' declared in enclosed function 'f'}}
+    int g() {
+      return x; // expected-error{{reference to local variable 'x' declared in enclosed function 'f'}}
+      return 1;
+    }
     int h() { return s; }
     int k() { return :: x; }
     int l() { return g(); }