aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/pr119612.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.dg/pr119612.c')
-rw-r--r--gcc/testsuite/gcc.dg/pr119612.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/pr119612.c b/gcc/testsuite/gcc.dg/pr119612.c
new file mode 100644
index 0000000..82bc5d9
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/pr119612.c
@@ -0,0 +1,9 @@
+/* PR c/119612
+ * { dg-do compile }
+ * { dg-options "-std=gnu23" }
+ * */
+
+int n = 3;
+void a(struct { char (*p)[n]; } *); /* { dg-warning "anonymous struct" } */
+void b(struct { char (*p)[n]; } *); /* { dg-warning "anonymous struct" } */
+