gcc/testsuite/g++.old-deja/g++.ext/jump1.C
raw| 1 | // { dg-do run } |
| 2 | // { dg-options "-fpermissive -w" } |
| 3 | // Test that we can jump over the declaration of a non-POD object. |
| 4 | // Contributed by Jason Merrill <[email protected]> |
| 5 | |
| 6 | struct A { }; |
| 7 | union U { |
| 8 | void (A::*p)(); |
| 9 | }; |
| 10 | |
| 11 | int main() |
| 12 | { |
| 13 | goto foo; |
| 14 | U u; |
| 15 | foo: |
| 16 | return 0; |
| 17 | } |