forked from OSchip/llvm-project
test: improve condition for the check
When the type of `wint_t` is `int`, the promotion will allow this to pass. Check this explicitly rather than using the size. llvm-svn: 342569
This commit is contained in:
parent
3461eae4a6
commit
241c33bca7
|
@ -401,7 +401,7 @@ void bug7377_bad_length_mod_usage() {
|
|||
void pr7981(wint_t c, wchar_t c2) {
|
||||
printf("%lc", c); // no-warning
|
||||
printf("%lc", 1.0); // expected-warning{{the argument has type 'double'}}
|
||||
#if __WINT_WIDTH__ == 4
|
||||
#if __WINT_TYPE__ == int
|
||||
printf("%lc", (char) 1); // no-warning
|
||||
#else
|
||||
printf("%lc", (char) 1); // expected-warning{{the argument has type 'char'}}
|
||||
|
|
Loading…
Reference in New Issue