[clang] Implement lifetime analysis for lifetime_capture_by(X) (#115921)
[llvm-project.git] / clang / test / Lexer / escape_newline_unicode.c
blob81a6429df48418225c6e0aa4606d7233d66a7762
1 // RUN: %clang_cc1 -verify=expected,c -x c -Wunused %s
2 // RUN: %clang_cc1 -verify=expected,cpp -x c++ -Wunused %s
4 void gh65156(void) {
6 int a\
7 = 42;
8 // expected-warning@-2 {{unused variable 'aス'}}
10 int b\
12 = 42;
13 // expected-warning@-2 {{backslash and newline separated by space}}
14 // expected-warning@-4 {{backslash and newline separated by space}}
15 // expected-warning@-5 {{unused variable 'bス'}}
17 int ス\
18 = 42;
19 // expected-warning@-2 {{unused variable 'スス'}}
21 int \
22 = 42;
23 // expected-warning@-2 {{unused variable 'ス'}}
27 void gh65156_err(void) {
29 int \
30 = 0;
31 // cpp-error@-2 {{expected unqualified-id}}
32 // c-error@-3 {{expected identifier}}
35 int a\
36 = 0;
37 // expected-error@-1 {{character <U+274C> not allowed in an identifier}}