diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/debug/dwarf2/pr43237.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/debug/dwarf2/pr43237.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/debug/dwarf2/pr43237.c b/gcc/testsuite/gcc.dg/debug/dwarf2/pr43237.c new file mode 100644 index 000000000..21262c3b2 --- /dev/null +++ b/gcc/testsuite/gcc.dg/debug/dwarf2/pr43237.c @@ -0,0 +1,31 @@ +/* PR debug/43237 */ +/* { dg-do compile } */ +/* { dg-options "-g -O2 -dA -fno-merge-debug-strings" } */ + +struct S +{ + int *a; + int b; + int **c; + int d; +}; + +void foo (struct S *); +void bar (struct S *); + +int +baz (void) +{ + struct S s; + foo (&s); + { + int a[s.b]; + int *c[s.d]; + s.a = a; + s.c = c; + bar (&s); + } + return 0; +} + +/* { dg-final { scan-assembler-not "LLST\[^\\r\\n\]*DW_AT_upper_bound" } } */ |