aboutsummaryrefslogtreecommitdiff
path: root/test/Sema/format-strings.c
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2010-12-02 20:57:51 +0000
committerTed Kremenek <kremenek@apple.com>2010-12-02 20:57:51 +0000
commit7966297a70996977f167a8676568f02f4283bdd6 (patch)
tree9947fd99f5f563017edf027b9dadc556e36d6adf /test/Sema/format-strings.c
parentb97c403176a5937575e7c5eea20026edfbe947f5 (diff)
Fix range in printf warnings for invalid conversion specifiers.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120735 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Sema/format-strings.c')
-rw-r--r--test/Sema/format-strings.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/Sema/format-strings.c b/test/Sema/format-strings.c
index ba5fa8a3a6..c51dafdae5 100644
--- a/test/Sema/format-strings.c
+++ b/test/Sema/format-strings.c
@@ -174,6 +174,7 @@ void test10(int x, float f, int i, long long lli) {
printf("%.0Lf", (long double) 1.0); // no-warning
printf("%c\n", "x"); // expected-warning{{conversion specifies type 'int' but the argument has type 'char *'}}
printf("%c\n", 1.23); // expected-warning{{conversion specifies type 'int' but the argument has type 'double'}}
+ printf("Format %d, is %! %f", 1, 2, 4.4); // expected-warning{{invalid conversion specifier '!'}}
}
typedef unsigned char uint8_t;