]> granicus.if.org Git - clang/commitdiff
clang/test/Sema/format-strings-scanf.c: Relax a couple of expressions with expected...
authorNAKAMURA Takumi <geek4civic@gmail.com>
Sat, 8 Sep 2012 12:06:00 +0000 (12:06 +0000)
committerNAKAMURA Takumi <geek4civic@gmail.com>
Sat, 8 Sep 2012 12:06:00 +0000 (12:06 +0000)
- format specifies type 'wchar_t **' (aka 'int **') but the argument has type 'float *'
- format specifies type 'wchar_t **' (aka 'unsigned short **') but the argument has type 'float *'

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163468 91177308-0d34-0410-b5e6-96231b3b80d8

test/Sema/format-strings-scanf.c

index be2adddc52b290c1a19d9f58d9fc1c30e3fb1626..d66bed5ffbd63b201da1bfa5d8f9a2f39a4ae219 100644 (file)
@@ -107,9 +107,9 @@ void test_alloc_extension(char **sp, wchar_t **lsp, float *fp) {
 
   // Test argument type check for the 'm' length modifier.
   scanf("%ms", fp); // expected-warning{{format specifies type 'char **' but the argument has type 'float *'}}
-  scanf("%mS", fp); // expected-warning{{format specifies type 'wchar_t **' (aka 'int **') but the argument has type 'float *'}}
+  scanf("%mS", fp); // expected-warning-re{{format specifies type 'wchar_t \*\*' \(aka '[^']+'\) but the argument has type 'float \*'}}
   scanf("%mc", fp); // expected-warning{{format specifies type 'char **' but the argument has type 'float *'}}
-  scanf("%mC", fp); // expected-warning{{format specifies type 'wchar_t **' (aka 'int **') but the argument has type 'float *'}}
+  scanf("%mC", fp); // expected-warning-re{{format specifies type 'wchar_t \*\*' \(aka '[^']+'\) but the argument has type 'float \*'}}
   scanf("%m[abc]", fp); // expected-warning{{format specifies type 'char **' but the argument has type 'float *'}}
 }