diff options
author | Chris Lattner <sabre@nondot.org> | 2010-09-05 23:29:49 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-09-05 23:29:49 +0000 |
commit | 6d6370ee10ddcd8cacc44c2d6796800c1325c732 (patch) | |
tree | 2235fbb067a4c51b0902efdb4bc91679f5ad1bfa /test/Sema/warn-write-strings.c | |
parent | 343d65c0739f9d4d6c6345a38a7228bafb1de4df (diff) |
fix PR7192 by defining wchar_t in a more conventional way. The
type of L"x" can change based on command line arguments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@113127 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Sema/warn-write-strings.c')
-rw-r--r-- | test/Sema/warn-write-strings.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/Sema/warn-write-strings.c b/test/Sema/warn-write-strings.c index 450d0a6fe6..dd0bb8a6d8 100644 --- a/test/Sema/warn-write-strings.c +++ b/test/Sema/warn-write-strings.c @@ -2,3 +2,9 @@ // PR4804 char* x = "foo"; // expected-warning {{initializing 'char *' with an expression of type 'const char [4]' discards qualifiers}} + +// PR7192 +#include <stddef.h> +void test(wchar_t *dst) { + dst[0] = 0; // Ok. +} |