diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2019-01-19 10:04:05 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2019-01-19 10:04:05 +0000 |
commit | 676fbe8105eeb6ff4bb2ed261cb212fcfdbe7b63 (patch) | |
tree | 02a1ac369cb734d0abfa5000dd86e5b7797e6a74 /test/Lexer/unicode.c | |
parent | c7e70c433efc6953dc3888b9fbf9f3512d7da2b0 (diff) |
Diffstat (limited to 'test/Lexer/unicode.c')
-rw-r--r-- | test/Lexer/unicode.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/Lexer/unicode.c b/test/Lexer/unicode.c index 30e353fa797e0..01285fbc21380 100644 --- a/test/Lexer/unicode.c +++ b/test/Lexer/unicode.c @@ -38,3 +38,15 @@ int n; = 3; // expected-warning {{treating Unicode character <U+037E> as identi int *n꞉꞉v = &n;; // expected-warning 2{{treating Unicode character <U+A789> as identifier character rather than as ':' symbol}} // expected-warning@-1 {{treating Unicode character <U+037E> as identifier character rather than as ';' symbol}} int v=[=](auto){return~x;}(); // expected-warning 12{{treating Unicode character}} + +int xx; +// expected-warning@-1 {{identifier contains Unicode character <U+2060> that is invisible in some environments}} +// expected-warning@-2 {{identifier contains Unicode character <U+FEFF> that is invisible in some environments}} +// expected-warning@-3 {{identifier contains Unicode character <U+200D> that is invisible in some environments}} +int foobar = 0; // expected-warning {{identifier contains Unicode character <U+200B> that is invisible in some environments}} +int x = foobar; // expected-error {{undeclared identifier}} + +int ∣foo; // expected-error {{non-ASCII character}} +#ifndef PP_ONLY +#define ∶ x // expected-error {{macro name must be an identifier}} +#endif |