summaryrefslogtreecommitdiffstats
path: root/test/CodeGenCXX/static-local-in-local-class.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGenCXX/static-local-in-local-class.cpp')
-rw-r--r--test/CodeGenCXX/static-local-in-local-class.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/CodeGenCXX/static-local-in-local-class.cpp b/test/CodeGenCXX/static-local-in-local-class.cpp
index d9e044c..ebf560a 100644
--- a/test/CodeGenCXX/static-local-in-local-class.cpp
+++ b/test/CodeGenCXX/static-local-in-local-class.cpp
@@ -19,3 +19,15 @@ void X::f() {
}
(void)i;
}
+
+// pr7101
+void foo() {
+ static int n = 0;
+ struct Helper {
+ static void Execute() {
+ n++;
+ }
+ };
+ Helper::Execute();
+}
+
OpenPOWER on IntegriCloud