summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.other/static10.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.other/static10.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.other/static10.C17
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.other/static10.C b/gcc/testsuite/g++.old-deja/g++.other/static10.C
new file mode 100644
index 000000000..16b152453
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.other/static10.C
@@ -0,0 +1,17 @@
+// { dg-do assemble }
+// { dg-options "-w" }
+// Origin: Ulrich Drepper <drepper@cygnus.com>
+
+struct st
+{
+ int a;
+};
+
+int
+foo (int a)
+{
+ static const st i = { 0 };
+
+ if (i.a == a)
+ return 0;
+}