| 1 |
/* { dg-do compile } */ |
| 2 |
/* Verify "-fdiagnostics-minimum-margin-width=0". */ |
| 3 |
/* { dg-options "-O -fdiagnostics-show-caret -fdiagnostics-show-line-numbers -fdiagnostics-minimum-margin-width=0" } */ |
| 4 |
|
| 5 |
/* This is a collection of unittests for diagnostic_show_locus; |
| 6 |
see the overview in diagnostic_plugin_test_show_locus.c. |
| 7 |
|
| 8 |
In particular, note the discussion of why we need a very long line here: |
| 9 |
01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 |
| 10 |
and that we can't use macros in this file. */ |
| 11 |
|
| 12 |
void test_simple (void) |
| 13 |
{ |
| 14 |
#if 0 |
| 15 |
myvar = myvar.x; /* { dg-warning "test" } */ |
| 16 |
|
| 17 |
/* { dg-begin-multiline-output "" } |
| 18 |
15 | myvar = myvar.x; |
| 19 |
| ~~~~~^~ |
| 20 |
{ dg-end-multiline-output "" } */ |
| 21 |
#endif |
| 22 |
} |