[docs] Add LICENSE.txt to the root of the mono-repo
[llvm-project.git] / clang / test / AST / ast-dump-expr.c
blob8605cd4bbaa160072011b8483fbedb6028afff34
1 // Test without serialization:
2 // RUN: %clang_cc1 -triple x86_64-unknown-unknown -Wno-unused-value -std=gnu11 -ast-dump %s \
3 // RUN: | FileCheck --strict-whitespace %s
4 //
5 // Test with serialization:
6 // RUN: %clang_cc1 -triple x86_64-unknown-unknown -Wno-unused-value -std=gnu11 -emit-pch -o %t %s
7 // RUN: %clang_cc1 -x c -triple x86_64-unknown-unknown -Wno-unused-value -std=gnu11 \
8 // RUN: -include-pch %t -ast-dump-all /dev/null \
9 // RUN: | sed -e "s/ <undeserialized declarations>//" -e "s/ imported//" \
10 // RUN: | FileCheck --strict-whitespace %s
12 void Comma(void) {
13 1, 2, 3;
14 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:9> 'int' ','
15 // CHECK-NEXT: BinaryOperator 0x{{[^ ]*}} <col:3, col:6> 'int' ','
16 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:3> 'int' 1
17 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:6> 'int' 2
18 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:9> 'int' 3
21 void Assignment(int a) {
22 a = 12;
23 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '='
24 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
25 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:7> 'int' 12
27 a += a;
28 // CHECK: CompoundAssignOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '+=' ComputeLHSTy='int' ComputeResultTy='int'
29 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
30 // CHECK-NEXT: ImplicitCastExpr
31 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
34 void Conditionals(int a) {
35 a ? 0 : 1;
36 // CHECK: ConditionalOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:11> 'int'
37 // CHECK-NEXT: ImplicitCastExpr
38 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
39 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:7> 'int' 0
40 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:11> 'int' 1
42 a ?: 0;
43 // CHECK: BinaryConditionalOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int'
44 // CHECK-NEXT: ImplicitCastExpr
45 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
46 // CHECK-NEXT: OpaqueValueExpr 0x{{[^ ]*}} <col:3> 'int'
47 // CHECK-NEXT: ImplicitCastExpr
48 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
49 // CHECK-NEXT: OpaqueValueExpr 0x{{[^ ]*}} <col:3> 'int'
50 // CHECK-NEXT: ImplicitCastExpr
51 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
52 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:8> 'int' 0
55 void BinaryOperators(int a, int b) {
56 // Logical operators
57 a || b;
58 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '||'
59 // CHECK-NEXT: ImplicitCastExpr
60 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
61 // CHECK-NEXT: ImplicitCastExpr
62 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
64 a && b;
65 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '&&'
66 // CHECK-NEXT: ImplicitCastExpr
67 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
68 // CHECK-NEXT: ImplicitCastExpr
69 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
71 // Bitwise operators
72 a | b;
73 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '|'
74 // CHECK-NEXT: ImplicitCastExpr
75 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
76 // CHECK-NEXT: ImplicitCastExpr
77 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
79 a ^ b;
80 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '^'
81 // CHECK-NEXT: ImplicitCastExpr
82 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
83 // CHECK-NEXT: ImplicitCastExpr
84 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
86 a & b;
87 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '&'
88 // CHECK-NEXT: ImplicitCastExpr
89 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
90 // CHECK-NEXT: ImplicitCastExpr
91 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
93 // Equality operators
94 a == b;
95 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '=='
96 // CHECK-NEXT: ImplicitCastExpr
97 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
98 // CHECK-NEXT: ImplicitCastExpr
99 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
101 a != b;
102 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '!='
103 // CHECK-NEXT: ImplicitCastExpr
104 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
105 // CHECK-NEXT: ImplicitCastExpr
106 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
108 // Relational operators
109 a < b;
110 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '<'
111 // CHECK-NEXT: ImplicitCastExpr
112 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
113 // CHECK-NEXT: ImplicitCastExpr
114 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
116 a > b;
117 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '>'
118 // CHECK-NEXT: ImplicitCastExpr
119 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
120 // CHECK-NEXT: ImplicitCastExpr
121 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
123 a <= b;
124 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '<='
125 // CHECK-NEXT: ImplicitCastExpr
126 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
127 // CHECK-NEXT: ImplicitCastExpr
128 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
130 a >= b;
131 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '>='
132 // CHECK-NEXT: ImplicitCastExpr
133 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
134 // CHECK-NEXT: ImplicitCastExpr
135 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
137 // Bit shifting operators
138 a << b;
139 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '<<'
140 // CHECK-NEXT: ImplicitCastExpr
141 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
142 // CHECK-NEXT: ImplicitCastExpr
143 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
145 a >> b;
146 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:8> 'int' '>>'
147 // CHECK-NEXT: ImplicitCastExpr
148 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
149 // CHECK-NEXT: ImplicitCastExpr
150 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:8> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
152 // Additive operators
153 a + b;
154 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '+'
155 // CHECK-NEXT: ImplicitCastExpr
156 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
157 // CHECK-NEXT: ImplicitCastExpr
158 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
160 a - b;
161 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '-'
162 // CHECK-NEXT: ImplicitCastExpr
163 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
164 // CHECK-NEXT: ImplicitCastExpr
165 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
167 // Multiplicative operators
168 a * b;
169 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '*'
170 // CHECK-NEXT: ImplicitCastExpr
171 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
172 // CHECK-NEXT: ImplicitCastExpr
173 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
175 a / b;
176 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '/'
177 // CHECK-NEXT: ImplicitCastExpr
178 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
179 // CHECK-NEXT: ImplicitCastExpr
180 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
182 a % b;
183 // CHECK: BinaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:7> 'int' '%'
184 // CHECK-NEXT: ImplicitCastExpr
185 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
186 // CHECK-NEXT: ImplicitCastExpr
187 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:7> 'int' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int'
190 void UnaryOperators(int a, int *b) {
191 // Cast operators
192 (float)a;
193 // CHECK: CStyleCastExpr 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:10> 'float' <IntegralToFloating>
194 // CHECK-NEXT: ImplicitCastExpr
195 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:10> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
197 // ++, --, and ~ are covered elsewhere.
200 // CHECK: UnaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:4> 'int' prefix '-'
201 // CHECK-NEXT: ImplicitCastExpr
202 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:4> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
205 // CHECK: UnaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:4> 'int' prefix '+' cannot overflow
206 // CHECK-NEXT: ImplicitCastExpr
207 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:4> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
210 // CHECK: UnaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:4> 'int *' prefix '&' cannot overflow
211 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:4> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
214 // CHECK: ImplicitCastExpr
215 // CHECK-NEXT: UnaryOperator 0x{{[^ ]*}} <col:3, col:4> 'int' lvalue prefix '*' cannot overflow
216 // CHECK-NEXT: ImplicitCastExpr
217 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:4> 'int *' lvalue ParmVar 0x{{[^ ]*}} 'b' 'int *'
220 // CHECK: UnaryOperator 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:4> 'int' prefix '!' cannot overflow
221 // CHECK-NEXT: ImplicitCastExpr
222 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:4> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
224 sizeof a;
225 // CHECK: UnaryExprOrTypeTraitExpr 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:10> 'unsigned long' sizeof
226 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:10> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
228 sizeof(int);
229 // CHECK: UnaryExprOrTypeTraitExpr 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:13> 'unsigned long' sizeof 'int'
231 _Alignof(int);
232 // FIXME: Uses C++ spelling for alignof in C mode.
233 // CHECK: UnaryExprOrTypeTraitExpr 0x{{[^ ]*}} <line:[[@LINE-2]]:3, col:15> 'unsigned long' alignof 'int'
236 struct S {
237 int a;
240 void PostfixOperators(int *a, struct S b, struct S *c) {
241 a[0];
242 // CHECK: ImplicitCastExpr
243 // CHECK-NEXT: ArraySubscriptExpr 0x{{[^ ]*}} <col:3, col:6> 'int' lvalue
244 // CHECK-NEXT: ImplicitCastExpr
245 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int *' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int *'
246 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:5> 'int' 0
248 UnaryOperators(*a, a);
249 // CHECK: CallExpr 0x{{[^ ]*}} <line:[[@LINE-1]]:3, col:23> 'void'
250 // CHECK-NEXT: ImplicitCastExpr
251 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'void (int, int *)' Function 0x{{[^ ]*}} 'UnaryOperators' 'void (int, int *)'
252 // CHECK-NEXT: ImplicitCastExpr
253 // CHECK-NEXT: UnaryOperator 0x{{[^ ]*}} <col:18, col:19> 'int' lvalue prefix '*' cannot overflow
254 // CHECK-NEXT: ImplicitCastExpr
255 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:19> 'int *' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int *'
256 // CHECK-NEXT: ImplicitCastExpr
257 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:22> 'int *' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int *'
259 b.a;
260 // CHECK: ImplicitCastExpr
261 // CHECK-NEXT: MemberExpr 0x{{[^ ]*}} <col:3, col:5> 'int' lvalue .a 0x{{[^ ]*}}
262 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'struct S':'struct S' lvalue ParmVar 0x{{[^ ]*}} 'b' 'struct S':'struct S'
264 c->a;
265 // CHECK: ImplicitCastExpr
266 // CHECK-NEXT: MemberExpr 0x{{[^ ]*}} <col:3, col:6> 'int' lvalue ->a 0x{{[^ ]*}}
267 // CHECK: ImplicitCastExpr
268 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'struct S *' lvalue ParmVar 0x{{[^ ]*}} 'c' 'struct S *'
270 // Postfix ++ and -- are covered elsewhere.
272 (int [4]){1, 2, 3, 4, };
273 // CHECK: ImplicitCastExpr
274 // CHECK-NEXT: CompoundLiteralExpr 0x{{[^ ]*}} <col:3, col:25> 'int[4]' lvalue
275 // CHECK-NEXT: InitListExpr 0x{{[^ ]*}} <col:12, col:25> 'int[4]'
276 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:13> 'int' 1
277 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:16> 'int' 2
278 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:19> 'int' 3
279 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:22> 'int' 4
281 (struct S){1};
282 // CHECK: ImplicitCastExpr
283 // CHECK-NEXT: CompoundLiteralExpr 0x{{[^ ]*}} <col:3, col:15> 'struct S':'struct S' lvalue
284 // CHECK-NEXT: InitListExpr 0x{{[^ ]*}} <col:13, col:15> 'struct S':'struct S'
285 // CHECK-NEXT: IntegerLiteral 0x{{[^ ]*}} <col:14> 'int' 1
288 enum E { One };
290 void PrimaryExpressions(int a) {
292 // CHECK: ImplicitCastExpr
293 // CHECK-NEXT: DeclRefExpr 0x{{[^ ]*}} <col:3> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
295 'a';
296 // CHECK: CharacterLiteral 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'int' 97
298 L'a';
299 // CHECK: CharacterLiteral 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'int' 97
301 "a";
302 // ImplicitCastExpr
303 // CHECK: StringLiteral 0x{{[^ ]*}} <col:3> 'char[2]' lvalue "a"
305 L"a";
306 // ImplicitCastExpr
307 // CHECK: StringLiteral 0x{{[^ ]*}} <col:3> 'int[2]' lvalue L"a"
309 u8"a";
310 // ImplicitCastExpr
311 // CHECK: StringLiteral 0x{{[^ ]*}} <col:3> 'char[2]' lvalue u8"a"
313 U"a";
314 // ImplicitCastExpr
315 // CHECK: StringLiteral 0x{{[^ ]*}} <col:3> 'unsigned int[2]' lvalue U"a"
317 u"a";
318 // ImplicitCastExpr
319 // CHECK: StringLiteral 0x{{[^ ]*}} <col:3> 'unsigned short[2]' lvalue u"a"
322 // CHECK: IntegerLiteral 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'int' 1
325 // CHECK: IntegerLiteral 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'unsigned int' 1
327 1ll;
328 // CHECK: IntegerLiteral 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'long long' 1
330 1.0;
331 // CHECK: FloatingLiteral 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'double' {{1\.[0]*e[\+]?[0]+}}
333 1.0f;
334 // CHECK: FloatingLiteral 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'float' {{1\.[0]*e[\+]?[0]+}}
336 1.0l;
337 // CHECK: FloatingLiteral 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'long double' {{1\.[0]*e[\+]?[0]+}}
339 One;
340 // CHECK: DeclRefExpr 0x{{[^ ]*}} <line:[[@LINE-1]]:3> 'int' EnumConstant 0x{{[^ ]*}} 'One' 'int'
342 (a);
343 // CHECK: ImplicitCastExpr
344 // CHECK-NEXT: ParenExpr 0x{{[^ ]*}} <col:3, col:5> 'int' lvalue
345 // CHECK: DeclRefExpr 0x{{[^ ]*}} <col:4> 'int' lvalue ParmVar 0x{{[^ ]*}} 'a' 'int'
347 // Generic selection expressions are covered elsewhere.