Anders Carlsson | 96b4adc | 2011-04-06 18:42:48 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -fsyntax-only -verify %s -fpascal-strings |
| 2 | const wchar_t *pascalString = L"\pThis is a Pascal string"; |
Anders Carlsson | b8fc45f | 2011-04-14 00:41:11 +0000 | [diff] [blame] | 3 | |
| 4 | unsigned char a[3] = "\pa"; |
| 5 | unsigned char b[3] = "\pab"; |
| 6 | unsigned char c[3] = "\pabc"; // expected-error {{initializer-string for char array is too long}} |
Richard Smith | 30ae1ed | 2013-05-05 16:40:13 +0000 | [diff] [blame] | 7 | unsigned char d[3] = ("\pab"); |
| 8 | unsigned char e[3] = ("\pabc"); // expected-error {{initializer-string for char array is too long}} |