testsuite: Skip analyzer tests on AIX.
[official-gcc.git] / gcc / testsuite / c-c++-common / diagnostic-format-sarif-file-bad-utf8-pr109098-1.c
blob47f89232b1176d4d585e49e7872a9a37a5d7a485
1 /* Try to process this explicitly as UTF-8.
3 { dg-do preprocess }
4 { dg-options "-finput-charset=UTF-8 -Winvalid-utf8 -fdiagnostics-format=sarif-file" } */
6 /* This comment intentionally contains non-UTF-8 bytes:
7 * €˜<unknown>€™ may be used uninitialized
8 */
10 /*
11 { dg-final { verify-sarif-file } }
13 Verify that we captured the expected warnings.
15 { dg-final { scan-sarif-file "\"results\": \\\[" } }
16 { dg-final { scan-sarif-file "\"level\": \"warning\"" } }
17 { dg-final { scan-sarif-file "\"ruleId\": \"-Winvalid-utf8\"" } }
18 { dg-final { scan-sarif-file "\"message\": " } }
19 { dg-final { scan-sarif-file {"text": "invalid UTF-8 character <80>"} } }
20 { dg-final { scan-sarif-file {"text": "invalid UTF-8 character <98>"} } }
21 { dg-final { scan-sarif-file {"text": "invalid UTF-8 character <80>"} } }
22 { dg-final { scan-sarif-file {"text": "invalid UTF-8 character <99>"} } }