Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/gcc.dg/pr79677.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 (2017-10-27) |
parents | |
children |
comparison
equal
deleted
inserted
replaced
68:561a7518be6b | 111:04ced10e8804 |
---|---|
1 /* PR c/79677 */ | |
2 /* { dg-do compile } */ | |
3 /* { dg-options "-Wformat -Werror=format-security -Wformat" } */ | |
4 /* { dg-message "some warnings being treated as errors" "" { target *-*-* } 0 } */ | |
5 | |
6 void foo (char *); | |
7 | |
8 int | |
9 main () | |
10 { | |
11 char s[10] = "%s"; | |
12 foo (s); | |
13 __builtin_printf (s); /* { dg-error "format not a string literal and no format arguments" } */ | |
14 return 0; | |
15 } |