diff options
Diffstat (limited to 'test/Sema/ms-wchar.c')
| -rw-r--r-- | test/Sema/ms-wchar.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/Sema/ms-wchar.c b/test/Sema/ms-wchar.c index 52a736c640..febaf283b3 100644 --- a/test/Sema/ms-wchar.c +++ b/test/Sema/ms-wchar.c @@ -12,4 +12,7 @@ __wchar_t g = L'a'; // expected-note {{previous}} unsigned short g; // expected-error {{redefinition of 'g' with a different type: 'unsigned short' vs '__wchar_t'}} // The type of a wide string literal is actually not __wchar_t. -__wchar_t s[] = L"Hello world!"; // expected-error {{array initializer must be an initializer list}} +__wchar_t s[] = L"Hello world!"; // expected-error-re {{array initializer must be an initializer list$}} + +// Do not suggest initializing with a string here, because it would not work. +__wchar_t t[] = 1; // expected-error-re {{array initializer must be an initializer list$}} |
