1 // { dg-options "-fdiagnostics-show-caret" }
3 #define TEST_1_DEPTH_0 throw bad_alloc; // { dg-line define_TEST_1_DEPTH_0 }
7 TEST_1_DEPTH_0 // { dg-line use_TEST_1_DEPTH_0 }
10 // { dg-error "'bad_alloc' was not declared in this scope" "" { target *-*-* } define_TEST_1_DEPTH_0 }
11 /* { dg-begin-multiline-output "" }
12 #define TEST_1_DEPTH_0 throw bad_alloc;
14 { dg-end-multiline-output "" } */
15 // { dg-message "in expansion of macro 'TEST_1_DEPTH_0'" "" { target *-*-* } use_TEST_1_DEPTH_0 }
16 /* { dg-begin-multiline-output "" }
19 { dg-end-multiline-output "" } */
22 #define TEST_2_DEPTH_0 throw bad_alloc; // { dg-line define_TEST_2_DEPTH_0 }
23 #define TEST_2_DEPTH_1 TEST_2_DEPTH_0 // { dg-line define_TEST_2_DEPTH_1 }
27 TEST_2_DEPTH_1 // { dg-line use_TEST_2_DEPTH_1 }
30 // { dg-error "'bad_alloc' was not declared in this scope" "" { target *-*-* } define_TEST_2_DEPTH_0 }
31 /* { dg-begin-multiline-output "" }
32 #define TEST_2_DEPTH_0 throw bad_alloc;
34 { dg-end-multiline-output "" } */
35 // { dg-message "in expansion of macro 'TEST_2_DEPTH_0'" "" { target *-*-* } define_TEST_2_DEPTH_1 }
36 /* { dg-begin-multiline-output "" }
37 #define TEST_2_DEPTH_1 TEST_2_DEPTH_0
39 { dg-end-multiline-output "" } */
40 // { dg-message "in expansion of macro 'TEST_2_DEPTH_1'" "" { target *-*-* } use_TEST_2_DEPTH_1 }
41 /* { dg-begin-multiline-output "" }
44 { dg-end-multiline-output "" } */