Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(23)

Side by Side Diff: pkg/compiler/lib/src/resolution/semantic_visitor_mixins.dart

Issue 1859343004: dartfmt pkg/compiler (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of dart2js.semantics_visitor; 5 part of dart2js.semantics_visitor;
6 6
7 /// Interface for bulk handling of a [Node] in a semantic visitor. 7 /// Interface for bulk handling of a [Node] in a semantic visitor.
8 abstract class BulkHandle<R, A> { 8 abstract class BulkHandle<R, A> {
9 /// Handle [node] either regardless of semantics or to report that [node] is 9 /// Handle [node] either regardless of semantics or to report that [node] is
10 /// unhandled. [message] contains a message template for the latter case: 10 /// unhandled. [message] contains a message template for the latter case:
11 /// Replace '#' in [message] by `node.toString()` to create a message for the 11 /// Replace '#' in [message] by `node.toString()` to create a message for the
12 /// error. 12 /// error.
13 R bulkHandleNode(Node node, String message, A arg); 13 R bulkHandleNode(Node node, String message, A arg);
14 } 14 }
15 15
16 /// Mixin that implements all `errorX` methods of [SemanticSendVisitor] by 16 /// Mixin that implements all `errorX` methods of [SemanticSendVisitor] by
17 /// delegating to a bulk handler. 17 /// delegating to a bulk handler.
18 /// 18 ///
19 /// Use this mixin to provide a trivial implementation for all `errorX` methods. 19 /// Use this mixin to provide a trivial implementation for all `errorX` methods.
20 abstract class ErrorBulkMixin<R, A> 20 abstract class ErrorBulkMixin<R, A>
21 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 21 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
22
23 // TODO(johnniwinther): Ensure that all error methods have an 22 // TODO(johnniwinther): Ensure that all error methods have an
24 // [ErroneousElement]. 23 // [ErroneousElement].
25 R bulkHandleError(Node node, ErroneousElement error, A arg) { 24 R bulkHandleError(Node node, ErroneousElement error, A arg) {
26 return bulkHandleNode(node, "Error expression `#` unhandled.", arg); 25 return bulkHandleNode(node, "Error expression `#` unhandled.", arg);
27 } 26 }
28 27
29 @override 28 @override
30 R errorNonConstantConstructorInvoke( 29 R errorNonConstantConstructorInvoke(NewExpression node, Element element,
31 NewExpression node, 30 DartType type, NodeList arguments, CallStructure callStructure, A arg) {
32 Element element,
33 DartType type,
34 NodeList arguments,
35 CallStructure callStructure,
36 A arg) {
37 return bulkHandleError(node, null, arg); 31 return bulkHandleError(node, null, arg);
38 } 32 }
39 33
40 @override 34 @override
41 R errorUndefinedUnaryExpression( 35 R errorUndefinedUnaryExpression(
42 Send node, 36 Send node, Operator operator, Node expression, A arg) {
43 Operator operator,
44 Node expression,
45 A arg) {
46 return bulkHandleError(node, null, arg); 37 return bulkHandleError(node, null, arg);
47 } 38 }
48 39
49 @override 40 @override
50 R errorUndefinedBinaryExpression( 41 R errorUndefinedBinaryExpression(
51 Send node, 42 Send node, Node left, Operator operator, Node right, A arg) {
52 Node left,
53 Operator operator,
54 Node right,
55 A arg) {
56 return bulkHandleError(node, null, arg); 43 return bulkHandleError(node, null, arg);
57 } 44 }
58 45
59 @override 46 @override
60 R errorInvalidCompound( 47 R errorInvalidCompound(Send node, ErroneousElement error,
61 Send node, 48 AssignmentOperator operator, Node rhs, A arg) {
62 ErroneousElement error,
63 AssignmentOperator operator,
64 Node rhs,
65 A arg) {
66 return bulkHandleError(node, error, arg); 49 return bulkHandleError(node, error, arg);
67 } 50 }
68 51
69 @override 52 @override
70 R errorInvalidGet( 53 R errorInvalidGet(Send node, ErroneousElement error, A arg) {
71 Send node,
72 ErroneousElement error,
73 A arg) {
74 return bulkHandleError(node, error, arg); 54 return bulkHandleError(node, error, arg);
75 } 55 }
76 56
77 @override 57 @override
78 R errorInvalidInvoke( 58 R errorInvalidInvoke(Send node, ErroneousElement error, NodeList arguments,
79 Send node, 59 Selector selector, A arg) {
80 ErroneousElement error,
81 NodeList arguments,
82 Selector selector,
83 A arg) {
84 return bulkHandleError(node, error, arg); 60 return bulkHandleError(node, error, arg);
85 } 61 }
86 62
87 @override 63 @override
88 R errorInvalidPostfix( 64 R errorInvalidPostfix(
89 Send node, 65 Send node, ErroneousElement error, IncDecOperator operator, A arg) {
90 ErroneousElement error,
91 IncDecOperator operator,
92 A arg) {
93 return bulkHandleError(node, error, arg); 66 return bulkHandleError(node, error, arg);
94 } 67 }
95 68
96 @override 69 @override
97 R errorInvalidPrefix( 70 R errorInvalidPrefix(
98 Send node, 71 Send node, ErroneousElement error, IncDecOperator operator, A arg) {
99 ErroneousElement error,
100 IncDecOperator operator,
101 A arg) {
102 return bulkHandleError(node, error, arg); 72 return bulkHandleError(node, error, arg);
103 } 73 }
104 74
105 @override 75 @override
106 R errorInvalidSet( 76 R errorInvalidSet(Send node, ErroneousElement error, Node rhs, A arg) {
107 Send node,
108 ErroneousElement error,
109 Node rhs,
110 A arg) {
111 return bulkHandleError(node, error, arg); 77 return bulkHandleError(node, error, arg);
112 } 78 }
113 79
114 @override 80 @override
115 R errorInvalidUnary( 81 R errorInvalidUnary(
116 Send node, 82 Send node, UnaryOperator operator, ErroneousElement error, A arg) {
117 UnaryOperator operator,
118 ErroneousElement error,
119 A arg) {
120 return bulkHandleError(node, error, arg); 83 return bulkHandleError(node, error, arg);
121 } 84 }
122 85
123 @override 86 @override
124 R errorInvalidEquals( 87 R errorInvalidEquals(Send node, ErroneousElement error, Node right, A arg) {
125 Send node,
126 ErroneousElement error,
127 Node right,
128 A arg) {
129 return bulkHandleError(node, error, arg); 88 return bulkHandleError(node, error, arg);
130 } 89 }
131 90
132 @override 91 @override
133 R errorInvalidNotEquals( 92 R errorInvalidNotEquals(
134 Send node, 93 Send node, ErroneousElement error, Node right, A arg) {
135 ErroneousElement error,
136 Node right,
137 A arg) {
138 return bulkHandleError(node, error, arg); 94 return bulkHandleError(node, error, arg);
139 } 95 }
140 96
141 @override 97 @override
142 R errorInvalidBinary( 98 R errorInvalidBinary(Send node, ErroneousElement error,
143 Send node, 99 BinaryOperator operator, Node right, A arg) {
144 ErroneousElement error,
145 BinaryOperator operator,
146 Node right,
147 A arg) {
148 return bulkHandleError(node, error, arg); 100 return bulkHandleError(node, error, arg);
149 } 101 }
150 102
151 @override 103 @override
152 R errorInvalidIndex( 104 R errorInvalidIndex(Send node, ErroneousElement error, Node index, A arg) {
153 Send node,
154 ErroneousElement error,
155 Node index,
156 A arg) {
157 return bulkHandleError(node, error, arg); 105 return bulkHandleError(node, error, arg);
158 } 106 }
159 107
160 @override 108 @override
161 R errorInvalidIndexSet( 109 R errorInvalidIndexSet(
162 Send node, 110 Send node, ErroneousElement error, Node index, Node rhs, A arg) {
163 ErroneousElement error,
164 Node index,
165 Node rhs,
166 A arg) {
167 return bulkHandleError(node, error, arg); 111 return bulkHandleError(node, error, arg);
168 } 112 }
169 113
170 @override 114 @override
171 R errorInvalidCompoundIndexSet( 115 R errorInvalidCompoundIndexSet(Send node, ErroneousElement error, Node index,
172 Send node, 116 AssignmentOperator operator, Node rhs, A arg) {
173 ErroneousElement error,
174 Node index,
175 AssignmentOperator operator,
176 Node rhs,
177 A arg) {
178 return bulkHandleError(node, error, arg); 117 return bulkHandleError(node, error, arg);
179 } 118 }
180 119
181 @override 120 @override
182 R errorInvalidIndexSetIfNull( 121 R errorInvalidIndexSetIfNull(
183 SendSet node, 122 SendSet node, ErroneousElement error, Node index, Node rhs, A arg) {
184 ErroneousElement error,
185 Node index,
186 Node rhs,
187 A arg) {
188 return bulkHandleError(node, error, arg); 123 return bulkHandleError(node, error, arg);
189 } 124 }
190 125
191 @override 126 @override
192 R errorInvalidIndexPrefix( 127 R errorInvalidIndexPrefix(Send node, ErroneousElement error, Node index,
193 Send node, 128 IncDecOperator operator, A arg) {
194 ErroneousElement error,
195 Node index,
196 IncDecOperator operator,
197 A arg) {
198 return bulkHandleError(node, error, arg); 129 return bulkHandleError(node, error, arg);
199 } 130 }
200 131
201 @override 132 @override
202 R errorInvalidIndexPostfix( 133 R errorInvalidIndexPostfix(Send node, ErroneousElement error, Node index,
203 Send node, 134 IncDecOperator operator, A arg) {
204 ErroneousElement error,
205 Node index,
206 IncDecOperator operator,
207 A arg) {
208 return bulkHandleError(node, error, arg); 135 return bulkHandleError(node, error, arg);
209 } 136 }
210 137
211 @override 138 @override
212 R errorInvalidSetIfNull( 139 R errorInvalidSetIfNull(Send node, ErroneousElement error, Node rhs, A arg) {
213 Send node,
214 ErroneousElement error,
215 Node rhs,
216 A arg) {
217 return bulkHandleError(node, error, arg); 140 return bulkHandleError(node, error, arg);
218 } 141 }
219 } 142 }
220 143
221 /// Mixin that implements all `visitXPrefix` methods of [SemanticSendVisitor] by 144 /// Mixin that implements all `visitXPrefix` methods of [SemanticSendVisitor] by
222 /// delegating to a bulk handler. 145 /// delegating to a bulk handler.
223 /// 146 ///
224 /// Use this mixin to provide a trivial implementation for all `visitXPrefix` 147 /// Use this mixin to provide a trivial implementation for all `visitXPrefix`
225 /// methods. 148 /// methods.
226 abstract class PrefixBulkMixin<R, A> 149 abstract class PrefixBulkMixin<R, A>
227 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 150 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
228
229 R bulkHandlePrefix(Send node, A arg) { 151 R bulkHandlePrefix(Send node, A arg) {
230 return bulkHandleNode(node, "Prefix expression `#` unhandled.", arg); 152 return bulkHandleNode(node, "Prefix expression `#` unhandled.", arg);
231 } 153 }
232 154
233 @override 155 @override
234 R visitDynamicPropertyPrefix( 156 R visitDynamicPropertyPrefix(
235 Send node, 157 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
236 Node receiver,
237 Name name,
238 IncDecOperator operator,
239 A arg) {
240 return bulkHandlePrefix(node, arg); 158 return bulkHandlePrefix(node, arg);
241 } 159 }
242 160
243 R visitIfNotNullDynamicPropertyPrefix( 161 R visitIfNotNullDynamicPropertyPrefix(
244 Send node, 162 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
245 Node receiver,
246 Name name,
247 IncDecOperator operator,
248 A arg) {
249 return bulkHandlePrefix(node, arg); 163 return bulkHandlePrefix(node, arg);
250 } 164 }
251 165
252 @override 166 @override
253 R visitIndexPrefix( 167 R visitIndexPrefix(
254 Send node, 168 Send node, Node receiver, Node index, IncDecOperator operator, A arg) {
255 Node receiver,
256 Node index,
257 IncDecOperator operator,
258 A arg) {
259 return bulkHandlePrefix(node, arg); 169 return bulkHandlePrefix(node, arg);
260 } 170 }
261 171
262 @override 172 @override
263 R visitLocalVariablePrefix( 173 R visitLocalVariablePrefix(Send node, LocalVariableElement variable,
264 Send node, 174 IncDecOperator operator, A arg) {
265 LocalVariableElement variable,
266 IncDecOperator operator,
267 A arg) {
268 return bulkHandlePrefix(node, arg); 175 return bulkHandlePrefix(node, arg);
269 } 176 }
270 177
271 @override 178 @override
272 R visitParameterPrefix( 179 R visitParameterPrefix(
273 Send node, 180 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
274 ParameterElement parameter,
275 IncDecOperator operator,
276 A arg) {
277 return bulkHandlePrefix(node, arg); 181 return bulkHandlePrefix(node, arg);
278 } 182 }
279 183
280 @override 184 @override
281 R visitStaticFieldPrefix( 185 R visitStaticFieldPrefix(
282 Send node, 186 Send node, FieldElement field, IncDecOperator operator, A arg) {
283 FieldElement field,
284 IncDecOperator operator,
285 A arg) {
286 return bulkHandlePrefix(node, arg); 187 return bulkHandlePrefix(node, arg);
287 } 188 }
288 189
289 @override 190 @override
290 R visitStaticGetterSetterPrefix( 191 R visitStaticGetterSetterPrefix(Send node, FunctionElement getter,
291 Send node, 192 FunctionElement setter, IncDecOperator operator, A arg) {
292 FunctionElement getter,
293 FunctionElement setter,
294 IncDecOperator operator,
295 A arg) {
296 return bulkHandlePrefix(node, arg); 193 return bulkHandlePrefix(node, arg);
297 } 194 }
298 195
299 @override 196 @override
300 R visitStaticMethodSetterPrefix( 197 R visitStaticMethodSetterPrefix(Send node, FunctionElement getter,
301 Send node, 198 FunctionElement setter, IncDecOperator operator, A arg) {
302 FunctionElement getter,
303 FunctionElement setter,
304 IncDecOperator operator,
305 A arg) {
306 return bulkHandlePrefix(node, arg); 199 return bulkHandlePrefix(node, arg);
307 } 200 }
308 201
309 @override 202 @override
310 R visitSuperFieldFieldPrefix( 203 R visitSuperFieldFieldPrefix(Send node, FieldElement readField,
311 Send node, 204 FieldElement writtenField, IncDecOperator operator, A arg) {
312 FieldElement readField,
313 FieldElement writtenField,
314 IncDecOperator operator,
315 A arg) {
316 return bulkHandlePrefix(node, arg); 205 return bulkHandlePrefix(node, arg);
317 } 206 }
318 207
319 @override 208 @override
320 R visitSuperFieldPrefix( 209 R visitSuperFieldPrefix(
321 Send node, 210 Send node, FieldElement field, IncDecOperator operator, A arg) {
322 FieldElement field,
323 IncDecOperator operator,
324 A arg) {
325 return bulkHandlePrefix(node, arg); 211 return bulkHandlePrefix(node, arg);
326 } 212 }
327 213
328 @override 214 @override
329 R visitSuperFieldSetterPrefix( 215 R visitSuperFieldSetterPrefix(Send node, FieldElement field,
330 Send node, 216 FunctionElement setter, IncDecOperator operator, A arg) {
331 FieldElement field,
332 FunctionElement setter,
333 IncDecOperator operator,
334 A arg) {
335 return bulkHandlePrefix(node, arg); 217 return bulkHandlePrefix(node, arg);
336 } 218 }
337 219
338 @override 220 @override
339 R visitSuperGetterFieldPrefix( 221 R visitSuperGetterFieldPrefix(Send node, FunctionElement getter,
340 Send node, 222 FieldElement field, IncDecOperator operator, A arg) {
341 FunctionElement getter,
342 FieldElement field,
343 IncDecOperator operator,
344 A arg) {
345 return bulkHandlePrefix(node, arg); 223 return bulkHandlePrefix(node, arg);
346 } 224 }
347 225
348 @override 226 @override
349 R visitSuperGetterSetterPrefix( 227 R visitSuperGetterSetterPrefix(Send node, FunctionElement getter,
350 Send node, 228 FunctionElement setter, IncDecOperator operator, A arg) {
351 FunctionElement getter,
352 FunctionElement setter,
353 IncDecOperator operator,
354 A arg) {
355 return bulkHandlePrefix(node, arg); 229 return bulkHandlePrefix(node, arg);
356 } 230 }
357 231
358 @override 232 @override
359 R visitSuperIndexPrefix( 233 R visitSuperIndexPrefix(
360 Send node, 234 Send node,
361 FunctionElement indexFunction, 235 FunctionElement indexFunction,
362 FunctionElement indexSetFunction, 236 FunctionElement indexSetFunction,
363 Node index, 237 Node index,
364 IncDecOperator operator, 238 IncDecOperator operator,
365 A arg) { 239 A arg) {
366 return bulkHandlePrefix(node, arg); 240 return bulkHandlePrefix(node, arg);
367 } 241 }
368 242
369 @override 243 @override
370 R visitUnresolvedSuperGetterIndexPrefix( 244 R visitUnresolvedSuperGetterIndexPrefix(Send node, Element element,
371 Send node, 245 MethodElement setter, Node index, IncDecOperator operator, A arg) {
372 Element element,
373 MethodElement setter,
374 Node index,
375 IncDecOperator operator,
376 A arg) {
377 return bulkHandlePrefix(node, arg); 246 return bulkHandlePrefix(node, arg);
378 } 247 }
379 248
380 @override 249 @override
381 R visitUnresolvedSuperSetterIndexPrefix( 250 R visitUnresolvedSuperSetterIndexPrefix(Send node, MethodElement getter,
382 Send node, 251 Element element, Node index, IncDecOperator operator, A arg) {
383 MethodElement getter,
384 Element element,
385 Node index,
386 IncDecOperator operator,
387 A arg) {
388 return bulkHandlePrefix(node, arg); 252 return bulkHandlePrefix(node, arg);
389 } 253 }
390 254
391 @override 255 @override
392 R visitUnresolvedSuperIndexPrefix( 256 R visitUnresolvedSuperIndexPrefix(
393 Send node, 257 Send node, Element element, Node index, IncDecOperator operator, A arg) {
394 Element element,
395 Node index,
396 IncDecOperator operator,
397 A arg) {
398 return bulkHandlePrefix(node, arg); 258 return bulkHandlePrefix(node, arg);
399 } 259 }
400 260
401 @override 261 @override
402 R visitSuperMethodSetterPrefix( 262 R visitSuperMethodSetterPrefix(Send node, FunctionElement method,
403 Send node, 263 FunctionElement setter, IncDecOperator operator, A arg) {
404 FunctionElement method,
405 FunctionElement setter,
406 IncDecOperator operator,
407 A arg) {
408 return bulkHandlePrefix(node, arg); 264 return bulkHandlePrefix(node, arg);
409 } 265 }
410 266
411 @override 267 @override
412 R visitThisPropertyPrefix( 268 R visitThisPropertyPrefix(
413 Send node, 269 Send node, Name name, IncDecOperator operator, A arg) {
414 Name name,
415 IncDecOperator operator,
416 A arg) {
417 return bulkHandlePrefix(node, arg); 270 return bulkHandlePrefix(node, arg);
418 } 271 }
419 272
420 @override 273 @override
421 R visitTopLevelFieldPrefix( 274 R visitTopLevelFieldPrefix(
422 Send node, 275 Send node, FieldElement field, IncDecOperator operator, A arg) {
423 FieldElement field,
424 IncDecOperator operator,
425 A arg) {
426 return bulkHandlePrefix(node, arg); 276 return bulkHandlePrefix(node, arg);
427 } 277 }
428 278
429 @override 279 @override
430 R visitTopLevelGetterSetterPrefix( 280 R visitTopLevelGetterSetterPrefix(Send node, FunctionElement getter,
431 Send node, 281 FunctionElement setter, IncDecOperator operator, A arg) {
432 FunctionElement getter,
433 FunctionElement setter,
434 IncDecOperator operator,
435 A arg) {
436 return bulkHandlePrefix(node, arg); 282 return bulkHandlePrefix(node, arg);
437 } 283 }
438 284
439 @override 285 @override
440 R visitTopLevelMethodSetterPrefix( 286 R visitTopLevelMethodSetterPrefix(Send node, FunctionElement method,
441 Send node, 287 FunctionElement setter, IncDecOperator operator, A arg) {
442 FunctionElement method,
443 FunctionElement setter,
444 IncDecOperator operator,
445 A arg) {
446 return bulkHandlePrefix(node, arg); 288 return bulkHandlePrefix(node, arg);
447 } 289 }
448 290
449 @override 291 @override
450 R visitClassTypeLiteralPrefix( 292 R visitClassTypeLiteralPrefix(
451 Send node, 293 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
452 ConstantExpression constant,
453 IncDecOperator operator,
454 A arg) {
455 return bulkHandlePrefix(node, arg); 294 return bulkHandlePrefix(node, arg);
456 } 295 }
457 296
458 @override 297 @override
459 R visitDynamicTypeLiteralPrefix( 298 R visitDynamicTypeLiteralPrefix(
460 Send node, 299 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
461 ConstantExpression constant,
462 IncDecOperator operator,
463 A arg) {
464 return bulkHandlePrefix(node, arg); 300 return bulkHandlePrefix(node, arg);
465 } 301 }
466 302
467 @override 303 @override
468 R visitLocalFunctionPrefix( 304 R visitLocalFunctionPrefix(Send node, LocalFunctionElement function,
469 Send node, 305 IncDecOperator operator, A arg) {
470 LocalFunctionElement function,
471 IncDecOperator operator,
472 A arg) {
473 return bulkHandlePrefix(node, arg); 306 return bulkHandlePrefix(node, arg);
474 } 307 }
475 308
476 @override 309 @override
477 R visitTypeVariableTypeLiteralPrefix( 310 R visitTypeVariableTypeLiteralPrefix(
478 Send node, 311 Send node, TypeVariableElement element, IncDecOperator operator, A arg) {
479 TypeVariableElement element,
480 IncDecOperator operator,
481 A arg) {
482 return bulkHandlePrefix(node, arg); 312 return bulkHandlePrefix(node, arg);
483 } 313 }
484 314
485 @override 315 @override
486 R visitTypedefTypeLiteralPrefix( 316 R visitTypedefTypeLiteralPrefix(
487 Send node, 317 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
488 ConstantExpression constant,
489 IncDecOperator operator,
490 A arg) {
491 return bulkHandlePrefix(node, arg); 318 return bulkHandlePrefix(node, arg);
492 } 319 }
493 320
494 @override 321 @override
495 R visitUnresolvedStaticGetterPrefix( 322 R visitUnresolvedStaticGetterPrefix(Send node, Element element,
496 Send node, 323 MethodElement setter, IncDecOperator operator, A arg) {
497 Element element,
498 MethodElement setter,
499 IncDecOperator operator,
500 A arg) {
501 return bulkHandlePrefix(node, arg); 324 return bulkHandlePrefix(node, arg);
502 } 325 }
503 326
504 @override 327 @override
505 R visitUnresolvedTopLevelGetterPrefix( 328 R visitUnresolvedTopLevelGetterPrefix(Send node, Element element,
506 Send node, 329 MethodElement setter, IncDecOperator operator, A arg) {
507 Element element,
508 MethodElement setter,
509 IncDecOperator operator,
510 A arg) {
511 return bulkHandlePrefix(node, arg); 330 return bulkHandlePrefix(node, arg);
512 } 331 }
513 332
514 @override 333 @override
515 R visitUnresolvedStaticSetterPrefix( 334 R visitUnresolvedStaticSetterPrefix(Send node, MethodElement getter,
516 Send node, 335 Element element, IncDecOperator operator, A arg) {
517 MethodElement getter,
518 Element element,
519 IncDecOperator operator,
520 A arg) {
521 return bulkHandlePrefix(node, arg); 336 return bulkHandlePrefix(node, arg);
522 } 337 }
523 338
524 @override 339 @override
525 R visitUnresolvedTopLevelSetterPrefix( 340 R visitUnresolvedTopLevelSetterPrefix(Send node, MethodElement getter,
526 Send node, 341 Element element, IncDecOperator operator, A arg) {
527 MethodElement getter,
528 Element element,
529 IncDecOperator operator,
530 A arg) {
531 return bulkHandlePrefix(node, arg); 342 return bulkHandlePrefix(node, arg);
532 } 343 }
533 344
534 @override 345 @override
535 R visitStaticMethodPrefix( 346 R visitStaticMethodPrefix(
536 Send node, 347 Send node, MethodElement method, IncDecOperator operator, A arg) {
537 MethodElement method,
538 IncDecOperator operator,
539 A arg) {
540 return bulkHandlePrefix(node, arg); 348 return bulkHandlePrefix(node, arg);
541 } 349 }
542 350
543 @override 351 @override
544 R visitTopLevelMethodPrefix( 352 R visitTopLevelMethodPrefix(
545 Send node, 353 Send node, MethodElement method, IncDecOperator operator, A arg) {
546 MethodElement method,
547 IncDecOperator operator,
548 A arg) {
549 return bulkHandlePrefix(node, arg); 354 return bulkHandlePrefix(node, arg);
550 } 355 }
551 356
552 @override 357 @override
553 R visitUnresolvedPrefix( 358 R visitUnresolvedPrefix(
554 Send node, 359 Send node, Element element, IncDecOperator operator, A arg) {
555 Element element,
556 IncDecOperator operator,
557 A arg) {
558 return bulkHandlePrefix(node, arg); 360 return bulkHandlePrefix(node, arg);
559 } 361 }
560 362
561 @override 363 @override
562 R visitFinalLocalVariablePrefix( 364 R visitFinalLocalVariablePrefix(Send node, LocalVariableElement variable,
563 Send node, 365 IncDecOperator operator, A arg) {
564 LocalVariableElement variable,
565 IncDecOperator operator,
566 A arg) {
567 return bulkHandlePrefix(node, arg); 366 return bulkHandlePrefix(node, arg);
568 } 367 }
569 368
570 @override 369 @override
571 R visitFinalParameterPrefix( 370 R visitFinalParameterPrefix(
572 Send node, 371 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
573 ParameterElement parameter,
574 IncDecOperator operator,
575 A arg) {
576 return bulkHandlePrefix(node, arg); 372 return bulkHandlePrefix(node, arg);
577 } 373 }
578 374
579 @override 375 @override
580 R visitFinalStaticFieldPrefix( 376 R visitFinalStaticFieldPrefix(
581 Send node, 377 Send node, FieldElement field, IncDecOperator operator, A arg) {
582 FieldElement field,
583 IncDecOperator operator,
584 A arg) {
585 return bulkHandlePrefix(node, arg); 378 return bulkHandlePrefix(node, arg);
586 } 379 }
587 380
588 @override 381 @override
589 R visitFinalSuperFieldPrefix( 382 R visitFinalSuperFieldPrefix(
590 Send node, 383 Send node, FieldElement field, IncDecOperator operator, A arg) {
591 FieldElement field,
592 IncDecOperator operator,
593 A arg) {
594 return bulkHandlePrefix(node, arg); 384 return bulkHandlePrefix(node, arg);
595 } 385 }
596 386
597 @override 387 @override
598 R visitSuperMethodPrefix( 388 R visitSuperMethodPrefix(
599 Send node, 389 Send node, FunctionElement method, IncDecOperator operator, A arg) {
600 FunctionElement method,
601 IncDecOperator operator,
602 A arg) {
603 return bulkHandlePrefix(node, arg); 390 return bulkHandlePrefix(node, arg);
604 } 391 }
605 392
606 @override 393 @override
607 R visitFinalTopLevelFieldPrefix( 394 R visitFinalTopLevelFieldPrefix(
608 Send node, 395 Send node, FieldElement field, IncDecOperator operator, A arg) {
609 FieldElement field,
610 IncDecOperator operator,
611 A arg) {
612 return bulkHandlePrefix(node, arg); 396 return bulkHandlePrefix(node, arg);
613 } 397 }
614 398
615 @override 399 @override
616 R visitUnresolvedSuperPrefix( 400 R visitUnresolvedSuperPrefix(
617 Send node, 401 Send node, Element element, IncDecOperator operator, A arg) {
618 Element element,
619 IncDecOperator operator,
620 A arg) {
621 return bulkHandlePrefix(node, arg); 402 return bulkHandlePrefix(node, arg);
622 } 403 }
623 404
624 @override 405 @override
625 R visitUnresolvedSuperGetterPrefix( 406 R visitUnresolvedSuperGetterPrefix(Send node, Element element,
626 Send node, 407 MethodElement setter, IncDecOperator operator, A arg) {
627 Element element,
628 MethodElement setter,
629 IncDecOperator operator,
630 A arg) {
631 return bulkHandlePrefix(node, arg); 408 return bulkHandlePrefix(node, arg);
632 } 409 }
633 410
634 @override 411 @override
635 R visitUnresolvedSuperSetterPrefix( 412 R visitUnresolvedSuperSetterPrefix(Send node, MethodElement getter,
636 Send node, 413 Element element, IncDecOperator operator, A arg) {
637 MethodElement getter,
638 Element element,
639 IncDecOperator operator,
640 A arg) {
641 return bulkHandlePrefix(node, arg); 414 return bulkHandlePrefix(node, arg);
642 } 415 }
643 } 416 }
644 417
645 /// Mixin that implements all `visitXPostfix` methods of [SemanticSendVisitor] 418 /// Mixin that implements all `visitXPostfix` methods of [SemanticSendVisitor]
646 /// by delegating to a bulk handler. 419 /// by delegating to a bulk handler.
647 /// 420 ///
648 /// Use this mixin to provide a trivial implementation for all `visitXPostfix` 421 /// Use this mixin to provide a trivial implementation for all `visitXPostfix`
649 /// methods. 422 /// methods.
650 abstract class PostfixBulkMixin<R, A> 423 abstract class PostfixBulkMixin<R, A>
651 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 424 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
652
653 R bulkHandlePostfix(Send node, A arg) { 425 R bulkHandlePostfix(Send node, A arg) {
654 return bulkHandleNode(node, "Postfix expression `#` unhandled.", arg); 426 return bulkHandleNode(node, "Postfix expression `#` unhandled.", arg);
655 } 427 }
656 428
657 @override 429 @override
658 R visitDynamicPropertyPostfix( 430 R visitDynamicPropertyPostfix(
659 Send node, 431 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
660 Node receiver,
661 Name name,
662 IncDecOperator operator,
663 A arg) {
664 return bulkHandlePostfix(node, arg); 432 return bulkHandlePostfix(node, arg);
665 } 433 }
666 434
667 @override 435 @override
668 R visitIfNotNullDynamicPropertyPostfix( 436 R visitIfNotNullDynamicPropertyPostfix(
669 Send node, 437 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
670 Node receiver,
671 Name name,
672 IncDecOperator operator,
673 A arg) {
674 return bulkHandlePostfix(node, arg); 438 return bulkHandlePostfix(node, arg);
675 } 439 }
676 440
677 R visitIndexPostfix( 441 R visitIndexPostfix(
678 Send node, 442 Send node, Node receiver, Node index, IncDecOperator operator, A arg) {
679 Node receiver,
680 Node index,
681 IncDecOperator operator,
682 A arg) {
683 return bulkHandlePostfix(node, arg); 443 return bulkHandlePostfix(node, arg);
684 } 444 }
685 445
686 @override 446 @override
687 R visitLocalVariablePostfix( 447 R visitLocalVariablePostfix(Send node, LocalVariableElement variable,
688 Send node, 448 IncDecOperator operator, A arg) {
689 LocalVariableElement variable,
690 IncDecOperator operator,
691 A arg) {
692 return bulkHandlePostfix(node, arg); 449 return bulkHandlePostfix(node, arg);
693 } 450 }
694 451
695 @override 452 @override
696 R visitParameterPostfix( 453 R visitParameterPostfix(
697 Send node, 454 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
698 ParameterElement parameter,
699 IncDecOperator operator,
700 A arg) {
701 return bulkHandlePostfix(node, arg); 455 return bulkHandlePostfix(node, arg);
702 } 456 }
703 457
704 @override 458 @override
705 R visitStaticFieldPostfix( 459 R visitStaticFieldPostfix(
706 Send node, 460 Send node, FieldElement field, IncDecOperator operator, A arg) {
707 FieldElement field,
708 IncDecOperator operator,
709 A arg) {
710 return bulkHandlePostfix(node, arg); 461 return bulkHandlePostfix(node, arg);
711 } 462 }
712 463
713 @override 464 @override
714 R visitStaticGetterSetterPostfix( 465 R visitStaticGetterSetterPostfix(Send node, FunctionElement getter,
715 Send node, 466 FunctionElement setter, IncDecOperator operator, A arg) {
716 FunctionElement getter,
717 FunctionElement setter,
718 IncDecOperator operator,
719 A arg) {
720 return bulkHandlePostfix(node, arg); 467 return bulkHandlePostfix(node, arg);
721 } 468 }
722 469
723 @override 470 @override
724 R visitStaticMethodSetterPostfix( 471 R visitStaticMethodSetterPostfix(Send node, FunctionElement getter,
725 Send node, 472 FunctionElement setter, IncDecOperator operator, A arg) {
726 FunctionElement getter,
727 FunctionElement setter,
728 IncDecOperator operator,
729 A arg) {
730 return bulkHandlePostfix(node, arg); 473 return bulkHandlePostfix(node, arg);
731 } 474 }
732 475
733 @override 476 @override
734 R visitSuperFieldFieldPostfix( 477 R visitSuperFieldFieldPostfix(Send node, FieldElement readField,
735 Send node, 478 FieldElement writtenField, IncDecOperator operator, A arg) {
736 FieldElement readField,
737 FieldElement writtenField,
738 IncDecOperator operator,
739 A arg) {
740 return bulkHandlePostfix(node, arg); 479 return bulkHandlePostfix(node, arg);
741 } 480 }
742 481
743 @override 482 @override
744 R visitSuperFieldPostfix( 483 R visitSuperFieldPostfix(
745 Send node, 484 Send node, FieldElement field, IncDecOperator operator, A arg) {
746 FieldElement field,
747 IncDecOperator operator,
748 A arg) {
749 return bulkHandlePostfix(node, arg); 485 return bulkHandlePostfix(node, arg);
750 } 486 }
751 487
752 @override 488 @override
753 R visitSuperFieldSetterPostfix( 489 R visitSuperFieldSetterPostfix(Send node, FieldElement field,
754 Send node, 490 FunctionElement setter, IncDecOperator operator, A arg) {
755 FieldElement field,
756 FunctionElement setter,
757 IncDecOperator operator,
758 A arg) {
759 return bulkHandlePostfix(node, arg); 491 return bulkHandlePostfix(node, arg);
760 } 492 }
761 493
762 @override 494 @override
763 R visitSuperGetterFieldPostfix( 495 R visitSuperGetterFieldPostfix(Send node, FunctionElement getter,
764 Send node, 496 FieldElement field, IncDecOperator operator, A arg) {
765 FunctionElement getter,
766 FieldElement field,
767 IncDecOperator operator,
768 A arg) {
769 return bulkHandlePostfix(node, arg); 497 return bulkHandlePostfix(node, arg);
770 } 498 }
771 499
772 @override 500 @override
773 R visitSuperGetterSetterPostfix( 501 R visitSuperGetterSetterPostfix(Send node, FunctionElement getter,
774 Send node, 502 FunctionElement setter, IncDecOperator operator, A arg) {
775 FunctionElement getter,
776 FunctionElement setter,
777 IncDecOperator operator,
778 A arg) {
779 return bulkHandlePostfix(node, arg); 503 return bulkHandlePostfix(node, arg);
780 } 504 }
781 505
782 @override 506 @override
783 R visitSuperIndexPostfix( 507 R visitSuperIndexPostfix(
784 Send node, 508 Send node,
785 FunctionElement indexFunction, 509 FunctionElement indexFunction,
786 FunctionElement indexSetFunction, 510 FunctionElement indexSetFunction,
787 Node index, 511 Node index,
788 IncDecOperator operator, 512 IncDecOperator operator,
789 A arg) { 513 A arg) {
790 return bulkHandlePostfix(node, arg); 514 return bulkHandlePostfix(node, arg);
791 } 515 }
792 516
793 @override 517 @override
794 R visitUnresolvedSuperGetterIndexPostfix( 518 R visitUnresolvedSuperGetterIndexPostfix(Send node, Element element,
795 Send node, 519 MethodElement setter, Node index, IncDecOperator operator, A arg) {
796 Element element,
797 MethodElement setter,
798 Node index,
799 IncDecOperator operator,
800 A arg) {
801 return bulkHandlePostfix(node, arg); 520 return bulkHandlePostfix(node, arg);
802 } 521 }
803 522
804 @override 523 @override
805 R visitUnresolvedSuperSetterIndexPostfix( 524 R visitUnresolvedSuperSetterIndexPostfix(Send node, MethodElement getter,
806 Send node, 525 Element element, Node index, IncDecOperator operator, A arg) {
807 MethodElement getter,
808 Element element,
809 Node index,
810 IncDecOperator operator,
811 A arg) {
812 return bulkHandlePostfix(node, arg); 526 return bulkHandlePostfix(node, arg);
813 } 527 }
814 528
815 @override 529 @override
816 R visitUnresolvedSuperIndexPostfix( 530 R visitUnresolvedSuperIndexPostfix(
817 Send node, 531 Send node, Element element, Node index, IncDecOperator operator, A arg) {
818 Element element,
819 Node index,
820 IncDecOperator operator,
821 A arg) {
822 return bulkHandlePostfix(node, arg); 532 return bulkHandlePostfix(node, arg);
823 } 533 }
824 534
825 @override 535 @override
826 R visitSuperMethodSetterPostfix( 536 R visitSuperMethodSetterPostfix(Send node, FunctionElement method,
827 Send node, 537 FunctionElement setter, IncDecOperator operator, A arg) {
828 FunctionElement method,
829 FunctionElement setter,
830 IncDecOperator operator,
831 A arg) {
832 return bulkHandlePostfix(node, arg); 538 return bulkHandlePostfix(node, arg);
833 } 539 }
834 540
835 @override 541 @override
836 R visitThisPropertyPostfix( 542 R visitThisPropertyPostfix(
837 Send node, 543 Send node, Name name, IncDecOperator operator, A arg) {
838 Name name,
839 IncDecOperator operator,
840 A arg) {
841 return bulkHandlePostfix(node, arg); 544 return bulkHandlePostfix(node, arg);
842 } 545 }
843 546
844 @override 547 @override
845 R visitTopLevelFieldPostfix( 548 R visitTopLevelFieldPostfix(
846 Send node, 549 Send node, FieldElement field, IncDecOperator operator, A arg) {
847 FieldElement field,
848 IncDecOperator operator,
849 A arg) {
850 return bulkHandlePostfix(node, arg); 550 return bulkHandlePostfix(node, arg);
851 } 551 }
852 552
853 @override 553 @override
854 R visitTopLevelGetterSetterPostfix( 554 R visitTopLevelGetterSetterPostfix(Send node, FunctionElement getter,
855 Send node, 555 FunctionElement setter, IncDecOperator operator, A arg) {
856 FunctionElement getter,
857 FunctionElement setter,
858 IncDecOperator operator,
859 A arg) {
860 return bulkHandlePostfix(node, arg); 556 return bulkHandlePostfix(node, arg);
861 } 557 }
862 558
863 @override 559 @override
864 R visitTopLevelMethodSetterPostfix( 560 R visitTopLevelMethodSetterPostfix(Send node, FunctionElement method,
865 Send node, 561 FunctionElement setter, IncDecOperator operator, A arg) {
866 FunctionElement method,
867 FunctionElement setter,
868 IncDecOperator operator,
869 A arg) {
870 return bulkHandlePostfix(node, arg); 562 return bulkHandlePostfix(node, arg);
871 } 563 }
872 564
873 @override 565 @override
874 R visitClassTypeLiteralPostfix( 566 R visitClassTypeLiteralPostfix(
875 Send node, 567 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
876 ConstantExpression constant,
877 IncDecOperator operator,
878 A arg) {
879 return bulkHandlePostfix(node, arg); 568 return bulkHandlePostfix(node, arg);
880 } 569 }
881 570
882 @override 571 @override
883 R visitDynamicTypeLiteralPostfix( 572 R visitDynamicTypeLiteralPostfix(
884 Send node, 573 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
885 ConstantExpression constant,
886 IncDecOperator operator,
887 A arg) {
888 return bulkHandlePostfix(node, arg); 574 return bulkHandlePostfix(node, arg);
889 } 575 }
890 576
891 @override 577 @override
892 R visitLocalFunctionPostfix( 578 R visitLocalFunctionPostfix(Send node, LocalFunctionElement function,
893 Send node, 579 IncDecOperator operator, A arg) {
894 LocalFunctionElement function,
895 IncDecOperator operator,
896 A arg) {
897 return bulkHandlePostfix(node, arg); 580 return bulkHandlePostfix(node, arg);
898 } 581 }
899 582
900 @override 583 @override
901 R visitTypeVariableTypeLiteralPostfix( 584 R visitTypeVariableTypeLiteralPostfix(
902 Send node, 585 Send node, TypeVariableElement element, IncDecOperator operator, A arg) {
903 TypeVariableElement element,
904 IncDecOperator operator,
905 A arg) {
906 return bulkHandlePostfix(node, arg); 586 return bulkHandlePostfix(node, arg);
907 } 587 }
908 588
909 @override 589 @override
910 R visitTypedefTypeLiteralPostfix( 590 R visitTypedefTypeLiteralPostfix(
911 Send node, 591 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
912 ConstantExpression constant,
913 IncDecOperator operator,
914 A arg) {
915 return bulkHandlePostfix(node, arg); 592 return bulkHandlePostfix(node, arg);
916 } 593 }
917 594
918 @override 595 @override
919 R visitUnresolvedStaticGetterPostfix( 596 R visitUnresolvedStaticGetterPostfix(Send node, Element element,
920 Send node, 597 MethodElement setter, IncDecOperator operator, A arg) {
921 Element element,
922 MethodElement setter,
923 IncDecOperator operator,
924 A arg) {
925 return bulkHandlePostfix(node, arg); 598 return bulkHandlePostfix(node, arg);
926 } 599 }
927 600
928 @override 601 @override
929 R visitUnresolvedTopLevelGetterPostfix( 602 R visitUnresolvedTopLevelGetterPostfix(Send node, Element element,
930 Send node, 603 MethodElement setter, IncDecOperator operator, A arg) {
931 Element element,
932 MethodElement setter,
933 IncDecOperator operator,
934 A arg) {
935 return bulkHandlePostfix(node, arg); 604 return bulkHandlePostfix(node, arg);
936 } 605 }
937 606
938 @override 607 @override
939 R visitUnresolvedStaticSetterPostfix( 608 R visitUnresolvedStaticSetterPostfix(Send node, MethodElement getter,
940 Send node, 609 Element element, IncDecOperator operator, A arg) {
941 MethodElement getter,
942 Element element,
943 IncDecOperator operator,
944 A arg) {
945 return bulkHandlePostfix(node, arg); 610 return bulkHandlePostfix(node, arg);
946 } 611 }
947 612
948 @override 613 @override
949 R visitUnresolvedTopLevelSetterPostfix( 614 R visitUnresolvedTopLevelSetterPostfix(Send node, MethodElement getter,
950 Send node, 615 Element element, IncDecOperator operator, A arg) {
951 MethodElement getter,
952 Element element,
953 IncDecOperator operator,
954 A arg) {
955 return bulkHandlePostfix(node, arg); 616 return bulkHandlePostfix(node, arg);
956 } 617 }
957 618
958 @override 619 @override
959 R visitStaticMethodPostfix( 620 R visitStaticMethodPostfix(
960 Send node, 621 Send node, MethodElement method, IncDecOperator operator, A arg) {
961 MethodElement method,
962 IncDecOperator operator,
963 A arg) {
964 return bulkHandlePostfix(node, arg); 622 return bulkHandlePostfix(node, arg);
965 } 623 }
966 624
967 R visitToplevelMethodPostfix( 625 R visitToplevelMethodPostfix(
968 Send node, 626 Send node, MethodElement method, IncDecOperator operator, A arg) {
969 MethodElement method,
970 IncDecOperator operator,
971 A arg) {
972 return bulkHandlePostfix(node, arg); 627 return bulkHandlePostfix(node, arg);
973 } 628 }
974 629
975 @override 630 @override
976 R visitUnresolvedPostfix( 631 R visitUnresolvedPostfix(
977 Send node, 632 Send node, Element element, IncDecOperator operator, A arg) {
978 Element element,
979 IncDecOperator operator,
980 A arg) {
981 return bulkHandlePostfix(node, arg); 633 return bulkHandlePostfix(node, arg);
982 } 634 }
983 635
984 @override 636 @override
985 R visitFinalLocalVariablePostfix( 637 R visitFinalLocalVariablePostfix(Send node, LocalVariableElement variable,
986 Send node, 638 IncDecOperator operator, A arg) {
987 LocalVariableElement variable,
988 IncDecOperator operator,
989 A arg) {
990 return bulkHandlePostfix(node, arg); 639 return bulkHandlePostfix(node, arg);
991 } 640 }
992 641
993 @override 642 @override
994 R visitFinalParameterPostfix( 643 R visitFinalParameterPostfix(
995 Send node, 644 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
996 ParameterElement parameter,
997 IncDecOperator operator,
998 A arg) {
999 return bulkHandlePostfix(node, arg); 645 return bulkHandlePostfix(node, arg);
1000 } 646 }
1001 647
1002 @override 648 @override
1003 R visitFinalStaticFieldPostfix( 649 R visitFinalStaticFieldPostfix(
1004 Send node, 650 Send node, FieldElement field, IncDecOperator operator, A arg) {
1005 FieldElement field,
1006 IncDecOperator operator,
1007 A arg) {
1008 return bulkHandlePostfix(node, arg); 651 return bulkHandlePostfix(node, arg);
1009 } 652 }
1010 653
1011 @override 654 @override
1012 R visitFinalSuperFieldPostfix( 655 R visitFinalSuperFieldPostfix(
1013 Send node, 656 Send node, FieldElement field, IncDecOperator operator, A arg) {
1014 FieldElement field,
1015 IncDecOperator operator,
1016 A arg) {
1017 return bulkHandlePostfix(node, arg); 657 return bulkHandlePostfix(node, arg);
1018 } 658 }
1019 659
1020 @override 660 @override
1021 R visitSuperMethodPostfix( 661 R visitSuperMethodPostfix(
1022 Send node, 662 Send node, FunctionElement method, IncDecOperator operator, A arg) {
1023 FunctionElement method,
1024 IncDecOperator operator,
1025 A arg) {
1026 return bulkHandlePostfix(node, arg); 663 return bulkHandlePostfix(node, arg);
1027 } 664 }
1028 665
1029 @override 666 @override
1030 R visitFinalTopLevelFieldPostfix( 667 R visitFinalTopLevelFieldPostfix(
1031 Send node, 668 Send node, FieldElement field, IncDecOperator operator, A arg) {
1032 FieldElement field,
1033 IncDecOperator operator,
1034 A arg) {
1035 return bulkHandlePostfix(node, arg); 669 return bulkHandlePostfix(node, arg);
1036 } 670 }
1037 671
1038 @override 672 @override
1039 R visitTopLevelMethodPostfix( 673 R visitTopLevelMethodPostfix(
1040 Send node, 674 Send node, MethodElement method, IncDecOperator operator, A arg) {
1041 MethodElement method,
1042 IncDecOperator operator,
1043 A arg) {
1044 return bulkHandlePostfix(node, arg); 675 return bulkHandlePostfix(node, arg);
1045 } 676 }
1046 677
1047 @override 678 @override
1048 R visitUnresolvedSuperPostfix( 679 R visitUnresolvedSuperPostfix(
1049 Send node, 680 Send node, Element element, IncDecOperator operator, A arg) {
1050 Element element,
1051 IncDecOperator operator,
1052 A arg) {
1053 return bulkHandlePostfix(node, arg); 681 return bulkHandlePostfix(node, arg);
1054 } 682 }
1055 683
1056 @override 684 @override
1057 R visitUnresolvedSuperGetterPostfix( 685 R visitUnresolvedSuperGetterPostfix(Send node, Element element,
1058 Send node, 686 MethodElement setter, IncDecOperator operator, A arg) {
1059 Element element,
1060 MethodElement setter,
1061 IncDecOperator operator,
1062 A arg) {
1063 return bulkHandlePostfix(node, arg); 687 return bulkHandlePostfix(node, arg);
1064 } 688 }
1065 689
1066 @override 690 @override
1067 R visitUnresolvedSuperSetterPostfix( 691 R visitUnresolvedSuperSetterPostfix(Send node, MethodElement getter,
1068 Send node, 692 Element element, IncDecOperator operator, A arg) {
1069 MethodElement getter,
1070 Element element,
1071 IncDecOperator operator,
1072 A arg) {
1073 return bulkHandlePostfix(node, arg); 693 return bulkHandlePostfix(node, arg);
1074 } 694 }
1075 } 695 }
1076 696
1077 /// Mixin that implements all `visitXCompound` methods of [SemanticSendVisitor] 697 /// Mixin that implements all `visitXCompound` methods of [SemanticSendVisitor]
1078 /// by delegating to a bulk handler. 698 /// by delegating to a bulk handler.
1079 /// 699 ///
1080 /// Use this mixin to provide a trivial implementation for all `xCompound` 700 /// Use this mixin to provide a trivial implementation for all `xCompound`
1081 /// methods. 701 /// methods.
1082 abstract class CompoundBulkMixin<R, A> 702 abstract class CompoundBulkMixin<R, A>
1083 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 703 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
1084
1085 R bulkHandleCompound(Send node, A arg) { 704 R bulkHandleCompound(Send node, A arg) {
1086 return bulkHandleNode(node, "Compound assignment `#` unhandled.", arg); 705 return bulkHandleNode(node, "Compound assignment `#` unhandled.", arg);
1087 } 706 }
1088 707
1089 @override 708 @override
1090 R visitDynamicPropertyCompound( 709 R visitDynamicPropertyCompound(Send node, Node receiver, Name name,
1091 Send node, 710 AssignmentOperator operator, Node rhs, A arg) {
1092 Node receiver, 711 return bulkHandleCompound(node, arg);
1093 Name name, 712 }
1094 AssignmentOperator operator, 713
1095 Node rhs, 714 @override
1096 A arg) { 715 R visitIfNotNullDynamicPropertyCompound(Send node, Node receiver, Name name,
1097 return bulkHandleCompound(node, arg); 716 AssignmentOperator operator, Node rhs, A arg) {
1098 } 717 return bulkHandleCompound(node, arg);
1099 718 }
1100 @override 719
1101 R visitIfNotNullDynamicPropertyCompound( 720 @override
1102 Send node, 721 R visitLocalVariableCompound(Send node, LocalVariableElement variable,
1103 Node receiver, 722 AssignmentOperator operator, Node rhs, A arg) {
1104 Name name, 723 return bulkHandleCompound(node, arg);
1105 AssignmentOperator operator, 724 }
1106 Node rhs, 725
1107 A arg) { 726 @override
1108 return bulkHandleCompound(node, arg); 727 R visitParameterCompound(Send node, ParameterElement parameter,
1109 } 728 AssignmentOperator operator, Node rhs, A arg) {
1110 729 return bulkHandleCompound(node, arg);
1111 @override 730 }
1112 R visitLocalVariableCompound( 731
1113 Send node, 732 @override
1114 LocalVariableElement variable, 733 R visitStaticFieldCompound(Send node, FieldElement field,
1115 AssignmentOperator operator, 734 AssignmentOperator operator, Node rhs, A arg) {
1116 Node rhs, 735 return bulkHandleCompound(node, arg);
1117 A arg) { 736 }
1118 return bulkHandleCompound(node, arg); 737
1119 } 738 @override
1120 739 R visitStaticGetterSetterCompound(Send node, FunctionElement getter,
1121 @override 740 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
1122 R visitParameterCompound( 741 return bulkHandleCompound(node, arg);
1123 Send node, 742 }
1124 ParameterElement parameter, 743
1125 AssignmentOperator operator, 744 @override
1126 Node rhs, 745 R visitStaticMethodSetterCompound(Send node, FunctionElement method,
1127 A arg) { 746 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
1128 return bulkHandleCompound(node, arg); 747 return bulkHandleCompound(node, arg);
1129 } 748 }
1130 749
1131 @override 750 @override
1132 R visitStaticFieldCompound( 751 R visitSuperFieldCompound(Send node, FieldElement field,
1133 Send node, 752 AssignmentOperator operator, Node rhs, A arg) {
1134 FieldElement field, 753 return bulkHandleCompound(node, arg);
1135 AssignmentOperator operator, 754 }
1136 Node rhs, 755
1137 A arg) { 756 @override
1138 return bulkHandleCompound(node, arg); 757 R visitSuperFieldSetterCompound(Send node, FieldElement field,
1139 } 758 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
1140 759 return bulkHandleCompound(node, arg);
1141 @override 760 }
1142 R visitStaticGetterSetterCompound( 761
1143 Send node, 762 @override
1144 FunctionElement getter, 763 R visitSuperGetterFieldCompound(Send node, FunctionElement getter,
1145 FunctionElement setter, 764 FieldElement field, AssignmentOperator operator, Node rhs, A arg) {
1146 AssignmentOperator operator, 765 return bulkHandleCompound(node, arg);
1147 Node rhs, 766 }
1148 A arg) { 767
1149 return bulkHandleCompound(node, arg); 768 @override
1150 } 769 R visitSuperGetterSetterCompound(Send node, FunctionElement getter,
1151 770 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
1152 @override 771 return bulkHandleCompound(node, arg);
1153 R visitStaticMethodSetterCompound( 772 }
1154 Send node, 773
1155 FunctionElement method, 774 @override
1156 FunctionElement setter, 775 R visitSuperMethodSetterCompound(Send node, FunctionElement method,
1157 AssignmentOperator operator, 776 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
1158 Node rhs,
1159 A arg) {
1160 return bulkHandleCompound(node, arg);
1161 }
1162
1163 @override
1164 R visitSuperFieldCompound(
1165 Send node,
1166 FieldElement field,
1167 AssignmentOperator operator,
1168 Node rhs,
1169 A arg) {
1170 return bulkHandleCompound(node, arg);
1171 }
1172
1173 @override
1174 R visitSuperFieldSetterCompound(
1175 Send node,
1176 FieldElement field,
1177 FunctionElement setter,
1178 AssignmentOperator operator,
1179 Node rhs,
1180 A arg) {
1181 return bulkHandleCompound(node, arg);
1182 }
1183
1184 @override
1185 R visitSuperGetterFieldCompound(
1186 Send node,
1187 FunctionElement getter,
1188 FieldElement field,
1189 AssignmentOperator operator,
1190 Node rhs,
1191 A arg) {
1192 return bulkHandleCompound(node, arg);
1193 }
1194
1195 @override
1196 R visitSuperGetterSetterCompound(
1197 Send node,
1198 FunctionElement getter,
1199 FunctionElement setter,
1200 AssignmentOperator operator,
1201 Node rhs,
1202 A arg) {
1203 return bulkHandleCompound(node, arg);
1204 }
1205
1206 @override
1207 R visitSuperMethodSetterCompound(
1208 Send node,
1209 FunctionElement method,
1210 FunctionElement setter,
1211 AssignmentOperator operator,
1212 Node rhs,
1213 A arg) {
1214 return bulkHandleCompound(node, arg); 777 return bulkHandleCompound(node, arg);
1215 } 778 }
1216 779
1217 @override 780 @override
1218 R visitThisPropertyCompound( 781 R visitThisPropertyCompound(
1219 Send node, 782 Send node, Name name, AssignmentOperator operator, Node rhs, A arg) {
1220 Name name, 783 return bulkHandleCompound(node, arg);
1221 AssignmentOperator operator, 784 }
1222 Node rhs, 785
1223 A arg) { 786 @override
1224 return bulkHandleCompound(node, arg); 787 R visitTopLevelFieldCompound(Send node, FieldElement field,
1225 } 788 AssignmentOperator operator, Node rhs, A arg) {
1226 789 return bulkHandleCompound(node, arg);
1227 @override 790 }
1228 R visitTopLevelFieldCompound( 791
1229 Send node, 792 @override
1230 FieldElement field, 793 R visitTopLevelGetterSetterCompound(Send node, FunctionElement getter,
1231 AssignmentOperator operator, 794 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
1232 Node rhs, 795 return bulkHandleCompound(node, arg);
1233 A arg) { 796 }
1234 return bulkHandleCompound(node, arg); 797
1235 } 798 @override
1236 799 R visitTopLevelMethodSetterCompound(Send node, FunctionElement method,
1237 @override 800 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
1238 R visitTopLevelGetterSetterCompound( 801 return bulkHandleCompound(node, arg);
1239 Send node, 802 }
1240 FunctionElement getter, 803
1241 FunctionElement setter, 804 @override
1242 AssignmentOperator operator, 805 R visitFinalParameterCompound(Send node, ParameterElement parameter,
1243 Node rhs, 806 AssignmentOperator operator, Node rhs, A arg) {
1244 A arg) { 807 return bulkHandleCompound(node, arg);
1245 return bulkHandleCompound(node, arg); 808 }
1246 } 809
1247 810 @override
1248 @override 811 R visitClassTypeLiteralCompound(Send node, ConstantExpression constant,
1249 R visitTopLevelMethodSetterCompound( 812 AssignmentOperator operator, Node rhs, A arg) {
1250 Send node, 813 return bulkHandleCompound(node, arg);
1251 FunctionElement method, 814 }
1252 FunctionElement setter, 815
1253 AssignmentOperator operator, 816 @override
1254 Node rhs, 817 R visitDynamicTypeLiteralCompound(Send node, ConstantExpression constant,
1255 A arg) { 818 AssignmentOperator operator, Node rhs, A arg) {
1256 return bulkHandleCompound(node, arg); 819 return bulkHandleCompound(node, arg);
1257 } 820 }
1258 821
1259 @override 822 @override
1260 R visitFinalParameterCompound( 823 R visitFinalLocalVariableCompound(Send node, LocalVariableElement variable,
1261 Send node, 824 AssignmentOperator operator, Node rhs, A arg) {
1262 ParameterElement parameter, 825 return bulkHandleCompound(node, arg);
1263 AssignmentOperator operator, 826 }
1264 Node rhs, 827
1265 A arg) { 828 @override
1266 return bulkHandleCompound(node, arg); 829 R visitFinalStaticFieldCompound(Send node, FieldElement field,
1267 } 830 AssignmentOperator operator, Node rhs, A arg) {
1268 831 return bulkHandleCompound(node, arg);
1269 @override 832 }
1270 R visitClassTypeLiteralCompound( 833
1271 Send node, 834 @override
1272 ConstantExpression constant, 835 R visitFinalSuperFieldCompound(Send node, FieldElement field,
1273 AssignmentOperator operator, 836 AssignmentOperator operator, Node rhs, A arg) {
1274 Node rhs, 837 return bulkHandleCompound(node, arg);
1275 A arg) { 838 }
1276 return bulkHandleCompound(node, arg); 839
1277 } 840 @override
1278 841 R visitFinalTopLevelFieldCompound(Send node, FieldElement field,
1279 @override 842 AssignmentOperator operator, Node rhs, A arg) {
1280 R visitDynamicTypeLiteralCompound( 843 return bulkHandleCompound(node, arg);
1281 Send node, 844 }
1282 ConstantExpression constant, 845
1283 AssignmentOperator operator, 846 @override
1284 Node rhs, 847 R visitLocalFunctionCompound(Send node, LocalFunctionElement function,
1285 A arg) { 848 AssignmentOperator operator, Node rhs, A arg) {
1286 return bulkHandleCompound(node, arg); 849 return bulkHandleCompound(node, arg);
1287 } 850 }
1288 851
1289 @override 852 @override
1290 R visitFinalLocalVariableCompound( 853 R visitTypeVariableTypeLiteralCompound(Send node, TypeVariableElement element,
1291 Send node, 854 AssignmentOperator operator, Node rhs, A arg) {
1292 LocalVariableElement 855 return bulkHandleCompound(node, arg);
1293 variable, 856 }
1294 AssignmentOperator operator, 857
1295 Node rhs, 858 @override
1296 A arg) { 859 R visitTypedefTypeLiteralCompound(Send node, ConstantExpression constant,
1297 return bulkHandleCompound(node, arg); 860 AssignmentOperator operator, Node rhs, A arg) {
1298 } 861 return bulkHandleCompound(node, arg);
1299 862 }
1300 @override 863
1301 R visitFinalStaticFieldCompound( 864 @override
1302 Send node, 865 R visitUnresolvedStaticGetterCompound(Send node, Element element,
1303 FieldElement field, 866 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
1304 AssignmentOperator operator, 867 return bulkHandleCompound(node, arg);
1305 Node rhs, 868 }
1306 A arg) { 869
1307 return bulkHandleCompound(node, arg); 870 @override
1308 } 871 R visitUnresolvedTopLevelGetterCompound(Send node, Element element,
1309 872 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
1310 @override 873 return bulkHandleCompound(node, arg);
1311 R visitFinalSuperFieldCompound( 874 }
1312 Send node, 875
1313 FieldElement field, 876 @override
1314 AssignmentOperator operator, 877 R visitUnresolvedStaticSetterCompound(Send node, MethodElement getter,
1315 Node rhs, 878 Element element, AssignmentOperator operator, Node rhs, A arg) {
1316 A arg) { 879 return bulkHandleCompound(node, arg);
1317 return bulkHandleCompound(node, arg); 880 }
1318 } 881
1319 882 @override
1320 @override 883 R visitUnresolvedTopLevelSetterCompound(Send node, MethodElement getter,
1321 R visitFinalTopLevelFieldCompound( 884 Element element, AssignmentOperator operator, Node rhs, A arg) {
1322 Send node, 885 return bulkHandleCompound(node, arg);
1323 FieldElement field, 886 }
1324 AssignmentOperator operator, 887
1325 Node rhs, 888 @override
1326 A arg) { 889 R visitStaticMethodCompound(Send node, MethodElement method,
1327 return bulkHandleCompound(node, arg); 890 AssignmentOperator operator, Node rhs, A arg) {
1328 } 891 return bulkHandleCompound(node, arg);
1329 892 }
1330 @override 893
1331 R visitLocalFunctionCompound( 894 @override
1332 Send node, 895 R visitTopLevelMethodCompound(Send node, MethodElement method,
1333 LocalFunctionElement function, 896 AssignmentOperator operator, Node rhs, A arg) {
1334 AssignmentOperator operator, 897 return bulkHandleCompound(node, arg);
1335 Node rhs, 898 }
1336 A arg) { 899
1337 return bulkHandleCompound(node, arg); 900 @override
1338 } 901 R visitUnresolvedCompound(Send node, Element element,
1339 902 AssignmentOperator operator, Node rhs, A arg) {
1340 @override 903 return bulkHandleCompound(node, arg);
1341 R visitTypeVariableTypeLiteralCompound( 904 }
1342 Send node, 905
1343 TypeVariableElement element, 906 @override
1344 AssignmentOperator operator, 907 R visitSuperFieldFieldCompound(Send node, FieldElement readField,
1345 Node rhs, 908 FieldElement writtenField, AssignmentOperator operator, Node rhs, A arg) {
1346 A arg) { 909 return bulkHandleCompound(node, arg);
1347 return bulkHandleCompound(node, arg); 910 }
1348 } 911
1349 912 @override
1350 @override 913 R visitSuperMethodCompound(Send node, FunctionElement method,
1351 R visitTypedefTypeLiteralCompound( 914 AssignmentOperator operator, Node rhs, A arg) {
1352 Send node, 915 return bulkHandleCompound(node, arg);
1353 ConstantExpression constant, 916 }
1354 AssignmentOperator operator, 917
1355 Node rhs, 918 @override
1356 A arg) { 919 R visitUnresolvedSuperCompound(Send node, Element element,
1357 return bulkHandleCompound(node, arg); 920 AssignmentOperator operator, Node rhs, A arg) {
1358 } 921 return bulkHandleCompound(node, arg);
1359 922 }
1360 @override 923
1361 R visitUnresolvedStaticGetterCompound( 924 @override
1362 Send node, 925 R visitUnresolvedSuperGetterCompound(Send node, Element element,
1363 Element element, 926 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
1364 MethodElement setter, 927 return bulkHandleCompound(node, arg);
1365 AssignmentOperator operator, 928 }
1366 Node rhs, 929
1367 A arg) { 930 @override
1368 return bulkHandleCompound(node, arg); 931 R visitUnresolvedSuperSetterCompound(Send node, MethodElement getter,
1369 } 932 Element element, AssignmentOperator operator, Node rhs, A arg) {
1370
1371 @override
1372 R visitUnresolvedTopLevelGetterCompound(
1373 Send node,
1374 Element element,
1375 MethodElement setter,
1376 AssignmentOperator operator,
1377 Node rhs,
1378 A arg) {
1379 return bulkHandleCompound(node, arg);
1380 }
1381
1382 @override
1383 R visitUnresolvedStaticSetterCompound(
1384 Send node,
1385 MethodElement getter,
1386 Element element,
1387 AssignmentOperator operator,
1388 Node rhs,
1389 A arg) {
1390 return bulkHandleCompound(node, arg);
1391 }
1392
1393 @override
1394 R visitUnresolvedTopLevelSetterCompound(
1395 Send node,
1396 MethodElement getter,
1397 Element element,
1398 AssignmentOperator operator,
1399 Node rhs,
1400 A arg) {
1401 return bulkHandleCompound(node, arg);
1402 }
1403
1404 @override
1405 R visitStaticMethodCompound(
1406 Send node,
1407 MethodElement method,
1408 AssignmentOperator operator,
1409 Node rhs,
1410 A arg) {
1411 return bulkHandleCompound(node, arg);
1412 }
1413
1414 @override
1415 R visitTopLevelMethodCompound(
1416 Send node,
1417 MethodElement method,
1418 AssignmentOperator operator,
1419 Node rhs,
1420 A arg) {
1421 return bulkHandleCompound(node, arg);
1422 }
1423
1424 @override
1425 R visitUnresolvedCompound(
1426 Send node,
1427 Element element,
1428 AssignmentOperator operator,
1429 Node rhs,
1430 A arg) {
1431 return bulkHandleCompound(node, arg);
1432 }
1433
1434 @override
1435 R visitSuperFieldFieldCompound(
1436 Send node, FieldElement readField,
1437 FieldElement writtenField,
1438 AssignmentOperator operator,
1439 Node rhs,
1440 A arg) {
1441 return bulkHandleCompound(node, arg);
1442 }
1443
1444 @override
1445 R visitSuperMethodCompound(
1446 Send node,
1447 FunctionElement method,
1448 AssignmentOperator operator,
1449 Node rhs,
1450 A arg) {
1451 return bulkHandleCompound(node, arg);
1452 }
1453
1454 @override
1455 R visitUnresolvedSuperCompound(
1456 Send node,
1457 Element element,
1458 AssignmentOperator operator,
1459 Node rhs,
1460 A arg) {
1461 return bulkHandleCompound(node, arg);
1462 }
1463
1464 @override
1465 R visitUnresolvedSuperGetterCompound(
1466 Send node, Element element,
1467 MethodElement setter,
1468 AssignmentOperator operator,
1469 Node rhs,
1470 A arg) {
1471 return bulkHandleCompound(node, arg);
1472 }
1473
1474 @override
1475 R visitUnresolvedSuperSetterCompound(
1476 Send node, MethodElement getter,
1477 Element element,
1478 AssignmentOperator operator,
1479 Node rhs,
1480 A arg) {
1481 return bulkHandleCompound(node, arg); 933 return bulkHandleCompound(node, arg);
1482 } 934 }
1483 } 935 }
1484 936
1485 /// Mixin that implements all `visitXSetIfNull` methods of [SemanticSendVisitor] 937 /// Mixin that implements all `visitXSetIfNull` methods of [SemanticSendVisitor]
1486 /// by delegating to a bulk handler. 938 /// by delegating to a bulk handler.
1487 /// 939 ///
1488 /// Use this mixin to provide a trivial implementation for all `xSetIfNull` 940 /// Use this mixin to provide a trivial implementation for all `xSetIfNull`
1489 /// methods. 941 /// methods.
1490 abstract class SetIfNullBulkMixin<R, A> 942 abstract class SetIfNullBulkMixin<R, A>
1491 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 943 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
1492
1493 R bulkHandleSetIfNull(Send node, A arg) { 944 R bulkHandleSetIfNull(Send node, A arg) {
1494 return bulkHandleNode(node, "If null assignment `#` unhandled.", arg); 945 return bulkHandleNode(node, "If null assignment `#` unhandled.", arg);
1495 } 946 }
1496 947
1497 @override 948 @override
1498 R visitClassTypeLiteralSetIfNull( 949 R visitClassTypeLiteralSetIfNull(
1499 Send node, 950 Send node, ConstantExpression constant, Node rhs, A arg) {
1500 ConstantExpression constant,
1501 Node rhs,
1502 A arg) {
1503 return bulkHandleSetIfNull(node, arg); 951 return bulkHandleSetIfNull(node, arg);
1504 } 952 }
1505 953
1506 @override 954 @override
1507 R visitDynamicPropertySetIfNull( 955 R visitDynamicPropertySetIfNull(
1508 Send node, 956 Send node, Node receiver, Name name, Node rhs, A arg) {
1509 Node receiver,
1510 Name name,
1511 Node rhs,
1512 A arg) {
1513 return bulkHandleSetIfNull(node, arg); 957 return bulkHandleSetIfNull(node, arg);
1514 } 958 }
1515 959
1516 @override 960 @override
1517 R visitDynamicTypeLiteralSetIfNull( 961 R visitDynamicTypeLiteralSetIfNull(
1518 Send node, 962 Send node, ConstantExpression constant, Node rhs, A arg) {
1519 ConstantExpression constant,
1520 Node rhs,
1521 A arg) {
1522 return bulkHandleSetIfNull(node, arg); 963 return bulkHandleSetIfNull(node, arg);
1523 } 964 }
1524 965
1525 @override 966 @override
1526 R visitFinalLocalVariableSetIfNull( 967 R visitFinalLocalVariableSetIfNull(
1527 Send node, 968 Send node, LocalVariableElement variable, Node rhs, A arg) {
1528 LocalVariableElement variable,
1529 Node rhs,
1530 A arg) {
1531 return bulkHandleSetIfNull(node, arg); 969 return bulkHandleSetIfNull(node, arg);
1532 } 970 }
1533 971
1534 @override 972 @override
1535 R visitFinalParameterSetIfNull( 973 R visitFinalParameterSetIfNull(
1536 Send node, 974 Send node, ParameterElement parameter, Node rhs, A arg) {
1537 ParameterElement parameter,
1538 Node rhs,
1539 A arg) {
1540 return bulkHandleSetIfNull(node, arg); 975 return bulkHandleSetIfNull(node, arg);
1541 } 976 }
1542 977
1543 @override 978 @override
1544 R visitFinalStaticFieldSetIfNull( 979 R visitFinalStaticFieldSetIfNull(
1545 Send node, 980 Send node, FieldElement field, Node rhs, A arg) {
1546 FieldElement field,
1547 Node rhs,
1548 A arg) {
1549 return bulkHandleSetIfNull(node, arg); 981 return bulkHandleSetIfNull(node, arg);
1550 } 982 }
1551 983
1552 @override 984 @override
1553 R visitFinalSuperFieldSetIfNull( 985 R visitFinalSuperFieldSetIfNull(
1554 Send node, 986 Send node, FieldElement field, Node rhs, A arg) {
1555 FieldElement field,
1556 Node rhs,
1557 A arg) {
1558 return bulkHandleSetIfNull(node, arg); 987 return bulkHandleSetIfNull(node, arg);
1559 } 988 }
1560 989
1561 @override 990 @override
1562 R visitFinalTopLevelFieldSetIfNull( 991 R visitFinalTopLevelFieldSetIfNull(
1563 Send node, 992 Send node, FieldElement field, Node rhs, A arg) {
1564 FieldElement field,
1565 Node rhs,
1566 A arg) {
1567 return bulkHandleSetIfNull(node, arg); 993 return bulkHandleSetIfNull(node, arg);
1568 } 994 }
1569 995
1570 @override 996 @override
1571 R visitIfNotNullDynamicPropertySetIfNull( 997 R visitIfNotNullDynamicPropertySetIfNull(
1572 Send node, 998 Send node, Node receiver, Name name, Node rhs, A arg) {
1573 Node receiver,
1574 Name name,
1575 Node rhs,
1576 A arg) {
1577 return bulkHandleSetIfNull(node, arg); 999 return bulkHandleSetIfNull(node, arg);
1578 } 1000 }
1579 1001
1580 @override 1002 @override
1581 R visitLocalFunctionSetIfNull( 1003 R visitLocalFunctionSetIfNull(
1582 Send node, 1004 Send node, LocalFunctionElement function, Node rhs, A arg) {
1583 LocalFunctionElement function,
1584 Node rhs,
1585 A arg) {
1586 return bulkHandleSetIfNull(node, arg); 1005 return bulkHandleSetIfNull(node, arg);
1587 } 1006 }
1588 1007
1589 @override 1008 @override
1590 R visitLocalVariableSetIfNull( 1009 R visitLocalVariableSetIfNull(
1591 Send node, 1010 Send node, LocalVariableElement variable, Node rhs, A arg) {
1592 LocalVariableElement variable,
1593 Node rhs,
1594 A arg) {
1595 return bulkHandleSetIfNull(node, arg); 1011 return bulkHandleSetIfNull(node, arg);
1596 } 1012 }
1597 1013
1598 @override 1014 @override
1599 R visitParameterSetIfNull( 1015 R visitParameterSetIfNull(
1600 Send node, 1016 Send node, ParameterElement parameter, Node rhs, A arg) {
1601 ParameterElement parameter, 1017 return bulkHandleSetIfNull(node, arg);
1602 Node rhs, 1018 }
1603 A arg) { 1019
1604 return bulkHandleSetIfNull(node, arg); 1020 @override
1605 } 1021 R visitStaticFieldSetIfNull(Send node, FieldElement field, Node rhs, A arg) {
1606 1022 return bulkHandleSetIfNull(node, arg);
1607 @override 1023 }
1608 R visitStaticFieldSetIfNull( 1024
1609 Send node, 1025 @override
1610 FieldElement field, 1026 R visitStaticGetterSetterSetIfNull(Send node, FunctionElement getter,
1611 Node rhs, 1027 FunctionElement setter, Node rhs, A arg) {
1612 A arg) {
1613 return bulkHandleSetIfNull(node, arg);
1614 }
1615
1616 @override
1617 R visitStaticGetterSetterSetIfNull(
1618 Send node,
1619 FunctionElement getter,
1620 FunctionElement setter,
1621 Node rhs,
1622 A arg) {
1623 return bulkHandleSetIfNull(node, arg); 1028 return bulkHandleSetIfNull(node, arg);
1624 } 1029 }
1625 1030
1626 @override 1031 @override
1627 R visitStaticMethodSetIfNull( 1032 R visitStaticMethodSetIfNull(
1628 Send node, 1033 Send node, FunctionElement method, Node rhs, A arg) {
1629 FunctionElement method,
1630 Node rhs,
1631 A arg) {
1632 return bulkHandleSetIfNull(node, arg); 1034 return bulkHandleSetIfNull(node, arg);
1633 } 1035 }
1634 1036
1635 @override 1037 @override
1636 R visitStaticMethodSetterSetIfNull( 1038 R visitStaticMethodSetterSetIfNull(
1637 Send node, 1039 Send node, MethodElement method, MethodElement setter, Node rhs, A arg) {
1638 MethodElement method, 1040 return bulkHandleSetIfNull(node, arg);
1639 MethodElement setter, 1041 }
1640 Node rhs, 1042
1641 A arg) { 1043 @override
1642 return bulkHandleSetIfNull(node, arg); 1044 R visitSuperFieldFieldSetIfNull(Send node, FieldElement readField,
1643 } 1045 FieldElement writtenField, Node rhs, A arg) {
1644 1046 return bulkHandleSetIfNull(node, arg);
1645 @override 1047 }
1646 R visitSuperFieldFieldSetIfNull( 1048
1647 Send node, 1049 @override
1648 FieldElement readField, 1050 R visitSuperFieldSetIfNull(Send node, FieldElement field, Node rhs, A arg) {
1649 FieldElement writtenField,
1650 Node rhs,
1651 A arg) {
1652 return bulkHandleSetIfNull(node, arg);
1653 }
1654
1655 @override
1656 R visitSuperFieldSetIfNull(
1657 Send node,
1658 FieldElement field,
1659 Node rhs,
1660 A arg) {
1661 return bulkHandleSetIfNull(node, arg); 1051 return bulkHandleSetIfNull(node, arg);
1662 } 1052 }
1663 1053
1664 @override 1054 @override
1665 R visitSuperFieldSetterSetIfNull( 1055 R visitSuperFieldSetterSetIfNull(
1666 Send node, 1056 Send node, FieldElement field, FunctionElement setter, Node rhs, A arg) {
1667 FieldElement field,
1668 FunctionElement setter,
1669 Node rhs,
1670 A arg) {
1671 return bulkHandleSetIfNull(node, arg); 1057 return bulkHandleSetIfNull(node, arg);
1672 } 1058 }
1673 1059
1674 @override 1060 @override
1675 R visitSuperGetterFieldSetIfNull( 1061 R visitSuperGetterFieldSetIfNull(
1676 Send node, 1062 Send node, FunctionElement getter, FieldElement field, Node rhs, A arg) {
1677 FunctionElement getter, 1063 return bulkHandleSetIfNull(node, arg);
1678 FieldElement field, 1064 }
1679 Node rhs, 1065
1680 A arg) { 1066 @override
1681 return bulkHandleSetIfNull(node, arg); 1067 R visitSuperGetterSetterSetIfNull(Send node, FunctionElement getter,
1682 } 1068 FunctionElement setter, Node rhs, A arg) {
1683
1684 @override
1685 R visitSuperGetterSetterSetIfNull(
1686 Send node,
1687 FunctionElement getter,
1688 FunctionElement setter,
1689 Node rhs,
1690 A arg) {
1691 return bulkHandleSetIfNull(node, arg); 1069 return bulkHandleSetIfNull(node, arg);
1692 } 1070 }
1693 1071
1694 @override 1072 @override
1695 R visitSuperMethodSetIfNull( 1073 R visitSuperMethodSetIfNull(
1696 Send node, 1074 Send node, FunctionElement method, Node rhs, A arg) {
1697 FunctionElement method, 1075 return bulkHandleSetIfNull(node, arg);
1698 Node rhs, 1076 }
1699 A arg) { 1077
1700 return bulkHandleSetIfNull(node, arg); 1078 @override
1701 } 1079 R visitSuperMethodSetterSetIfNull(Send node, FunctionElement method,
1702 1080 FunctionElement setter, Node rhs, A arg) {
1703 @override 1081 return bulkHandleSetIfNull(node, arg);
1704 R visitSuperMethodSetterSetIfNull( 1082 }
1705 Send node, 1083
1706 FunctionElement method, 1084 @override
1707 FunctionElement setter, 1085 R visitThisPropertySetIfNull(Send node, Name name, Node rhs, A arg) {
1708 Node rhs,
1709 A arg) {
1710 return bulkHandleSetIfNull(node, arg);
1711 }
1712
1713 @override
1714 R visitThisPropertySetIfNull(
1715 Send node,
1716 Name name,
1717 Node rhs,
1718 A arg) {
1719 return bulkHandleSetIfNull(node, arg); 1086 return bulkHandleSetIfNull(node, arg);
1720 } 1087 }
1721 1088
1722 @override 1089 @override
1723 R visitTopLevelFieldSetIfNull( 1090 R visitTopLevelFieldSetIfNull(
1724 Send node, 1091 Send node, FieldElement field, Node rhs, A arg) {
1725 FieldElement field, 1092 return bulkHandleSetIfNull(node, arg);
1726 Node rhs, 1093 }
1727 A arg) { 1094
1728 return bulkHandleSetIfNull(node, arg); 1095 @override
1729 } 1096 R visitTopLevelGetterSetterSetIfNull(Send node, FunctionElement getter,
1730 1097 FunctionElement setter, Node rhs, A arg) {
1731 @override
1732 R visitTopLevelGetterSetterSetIfNull(
1733 Send node,
1734 FunctionElement getter,
1735 FunctionElement setter,
1736 Node rhs,
1737 A arg) {
1738 return bulkHandleSetIfNull(node, arg); 1098 return bulkHandleSetIfNull(node, arg);
1739 } 1099 }
1740 1100
1741 @override 1101 @override
1742 R visitTopLevelMethodSetIfNull( 1102 R visitTopLevelMethodSetIfNull(
1743 Send node, 1103 Send node, FunctionElement method, Node rhs, A arg) {
1744 FunctionElement method, 1104 return bulkHandleSetIfNull(node, arg);
1745 Node rhs, 1105 }
1746 A arg) { 1106
1747 return bulkHandleSetIfNull(node, arg); 1107 @override
1748 } 1108 R visitTopLevelMethodSetterSetIfNull(Send node, FunctionElement method,
1749 1109 FunctionElement setter, Node rhs, A arg) {
1750 @override
1751 R visitTopLevelMethodSetterSetIfNull(
1752 Send node,
1753 FunctionElement method,
1754 FunctionElement setter,
1755 Node rhs,
1756 A arg) {
1757 return bulkHandleSetIfNull(node, arg); 1110 return bulkHandleSetIfNull(node, arg);
1758 } 1111 }
1759 1112
1760 @override 1113 @override
1761 R visitTypeVariableTypeLiteralSetIfNull( 1114 R visitTypeVariableTypeLiteralSetIfNull(
1762 Send node, 1115 Send node, TypeVariableElement element, Node rhs, A arg) {
1763 TypeVariableElement element,
1764 Node rhs,
1765 A arg) {
1766 return bulkHandleSetIfNull(node, arg); 1116 return bulkHandleSetIfNull(node, arg);
1767 } 1117 }
1768 1118
1769 @override 1119 @override
1770 R visitTypedefTypeLiteralSetIfNull( 1120 R visitTypedefTypeLiteralSetIfNull(
1771 Send node, 1121 Send node, ConstantExpression constant, Node rhs, A arg) {
1772 ConstantExpression constant, 1122 return bulkHandleSetIfNull(node, arg);
1773 Node rhs, 1123 }
1774 A arg) { 1124
1775 return bulkHandleSetIfNull(node, arg); 1125 @override
1776 } 1126 R visitUnresolvedSetIfNull(Send node, Element element, Node rhs, A arg) {
1777
1778 @override
1779 R visitUnresolvedSetIfNull(
1780 Send node,
1781 Element element,
1782 Node rhs,
1783 A arg) {
1784 return bulkHandleSetIfNull(node, arg); 1127 return bulkHandleSetIfNull(node, arg);
1785 } 1128 }
1786 1129
1787 @override 1130 @override
1788 R visitUnresolvedStaticGetterSetIfNull( 1131 R visitUnresolvedStaticGetterSetIfNull(
1789 Send node, 1132 Send node, Element element, MethodElement setter, Node rhs, A arg) {
1790 Element element,
1791 MethodElement setter,
1792 Node rhs,
1793 A arg) {
1794 return bulkHandleSetIfNull(node, arg); 1133 return bulkHandleSetIfNull(node, arg);
1795 } 1134 }
1796 1135
1797 @override 1136 @override
1798 R visitUnresolvedStaticSetterSetIfNull( 1137 R visitUnresolvedStaticSetterSetIfNull(
1799 Send node, 1138 Send node, MethodElement getter, Element element, Node rhs, A arg) {
1800 MethodElement getter,
1801 Element element,
1802 Node rhs,
1803 A arg) {
1804 return bulkHandleSetIfNull(node, arg); 1139 return bulkHandleSetIfNull(node, arg);
1805 } 1140 }
1806 1141
1807 @override 1142 @override
1808 R visitUnresolvedSuperGetterSetIfNull( 1143 R visitUnresolvedSuperGetterSetIfNull(
1809 Send node, 1144 Send node, Element element, MethodElement setter, Node rhs, A arg) {
1810 Element element, 1145 return bulkHandleSetIfNull(node, arg);
1811 MethodElement setter, 1146 }
1812 Node rhs, 1147
1813 A arg) { 1148 @override
1814 return bulkHandleSetIfNull(node, arg); 1149 R visitUnresolvedSuperSetIfNull(Send node, Element element, Node rhs, A arg) {
1815 }
1816
1817 @override
1818 R visitUnresolvedSuperSetIfNull(
1819 Send node,
1820 Element element,
1821 Node rhs,
1822 A arg) {
1823 return bulkHandleSetIfNull(node, arg); 1150 return bulkHandleSetIfNull(node, arg);
1824 } 1151 }
1825 1152
1826 @override 1153 @override
1827 R visitUnresolvedSuperSetterSetIfNull( 1154 R visitUnresolvedSuperSetterSetIfNull(
1828 Send node, 1155 Send node, MethodElement getter, Element element, Node rhs, A arg) {
1829 MethodElement getter,
1830 Element element,
1831 Node rhs,
1832 A arg) {
1833 return bulkHandleSetIfNull(node, arg); 1156 return bulkHandleSetIfNull(node, arg);
1834 } 1157 }
1835 1158
1836 @override 1159 @override
1837 R visitUnresolvedTopLevelGetterSetIfNull( 1160 R visitUnresolvedTopLevelGetterSetIfNull(
1838 Send node, 1161 Send node, Element element, MethodElement setter, Node rhs, A arg) {
1839 Element element,
1840 MethodElement setter,
1841 Node rhs,
1842 A arg) {
1843 return bulkHandleSetIfNull(node, arg); 1162 return bulkHandleSetIfNull(node, arg);
1844 } 1163 }
1845 1164
1846 @override 1165 @override
1847 R visitUnresolvedTopLevelSetterSetIfNull( 1166 R visitUnresolvedTopLevelSetterSetIfNull(
1848 Send node, 1167 Send node, MethodElement getter, Element element, Node rhs, A arg) {
1849 MethodElement getter,
1850 Element element,
1851 Node rhs,
1852 A arg) {
1853 return bulkHandleSetIfNull(node, arg); 1168 return bulkHandleSetIfNull(node, arg);
1854 } 1169 }
1855 1170
1856 @override 1171 @override
1857 R visitIndexSetIfNull( 1172 R visitIndexSetIfNull(
1858 SendSet node, 1173 SendSet node, Node receiver, Node index, Node rhs, A arg) {
1859 Node receiver, 1174 return bulkHandleSetIfNull(node, arg);
1860 Node index, 1175 }
1861 Node rhs, 1176
1862 A arg) { 1177 @override
1863 return bulkHandleSetIfNull(node, arg); 1178 R visitSuperIndexSetIfNull(SendSet node, MethodElement getter,
1864 } 1179 MethodElement setter, Node index, Node rhs, A arg) {
1865 1180 return bulkHandleSetIfNull(node, arg);
1866 @override 1181 }
1867 R visitSuperIndexSetIfNull( 1182
1868 SendSet node, 1183 @override
1869 MethodElement getter, 1184 R visitUnresolvedSuperGetterIndexSetIfNull(Send node, Element element,
1870 MethodElement setter, 1185 MethodElement setter, Node index, Node rhs, A arg) {
1871 Node index, 1186 return bulkHandleSetIfNull(node, arg);
1872 Node rhs, 1187 }
1873 A arg) { 1188
1874 return bulkHandleSetIfNull(node, arg); 1189 @override
1875 } 1190 R visitUnresolvedSuperSetterIndexSetIfNull(Send node, MethodElement getter,
1876 1191 Element element, Node index, Node rhs, A arg) {
1877 @override
1878 R visitUnresolvedSuperGetterIndexSetIfNull(
1879 Send node,
1880 Element element,
1881 MethodElement setter,
1882 Node index,
1883 Node rhs,
1884 A arg) {
1885 return bulkHandleSetIfNull(node, arg);
1886 }
1887
1888 @override
1889 R visitUnresolvedSuperSetterIndexSetIfNull(
1890 Send node,
1891 MethodElement getter,
1892 Element element,
1893 Node index,
1894 Node rhs,
1895 A arg) {
1896 return bulkHandleSetIfNull(node, arg); 1192 return bulkHandleSetIfNull(node, arg);
1897 } 1193 }
1898 1194
1899 @override 1195 @override
1900 R visitUnresolvedSuperIndexSetIfNull( 1196 R visitUnresolvedSuperIndexSetIfNull(
1901 Send node, 1197 Send node, Element element, Node index, Node rhs, A arg) {
1902 Element element,
1903 Node index,
1904 Node rhs,
1905 A arg) {
1906 return bulkHandleSetIfNull(node, arg); 1198 return bulkHandleSetIfNull(node, arg);
1907 } 1199 }
1908 } 1200 }
1909 1201
1910 /// Mixin that implements all `visitXInvoke` methods of [SemanticSendVisitor] by 1202 /// Mixin that implements all `visitXInvoke` methods of [SemanticSendVisitor] by
1911 /// delegating to a bulk handler. 1203 /// delegating to a bulk handler.
1912 /// 1204 ///
1913 /// Use this mixin to provide a trivial implementation for all `visitXInvoke` 1205 /// Use this mixin to provide a trivial implementation for all `visitXInvoke`
1914 /// methods. 1206 /// methods.
1915 abstract class InvokeBulkMixin<R, A> 1207 abstract class InvokeBulkMixin<R, A>
1916 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 1208 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
1917
1918 R bulkHandleInvoke(Send node, A arg) { 1209 R bulkHandleInvoke(Send node, A arg) {
1919 return bulkHandleNode(node, "Invocation `#` unhandled.", arg); 1210 return bulkHandleNode(node, "Invocation `#` unhandled.", arg);
1920 } 1211 }
1921 1212
1922 @override 1213 @override
1923 R visitClassTypeLiteralInvoke( 1214 R visitClassTypeLiteralInvoke(Send node, ConstantExpression constant,
1924 Send node, 1215 NodeList arguments, CallStructure callStructure, A arg) {
1925 ConstantExpression constant,
1926 NodeList arguments,
1927 CallStructure callStructure,
1928 A arg) {
1929 return bulkHandleInvoke(node, arg); 1216 return bulkHandleInvoke(node, arg);
1930 } 1217 }
1931 1218
1932 @override 1219 @override
1933 R visitDynamicPropertyInvoke( 1220 R visitDynamicPropertyInvoke(
1934 Send node, 1221 Send node, Node receiver, NodeList arguments, Selector selector, A arg) {
1935 Node receiver,
1936 NodeList arguments,
1937 Selector selector,
1938 A arg) {
1939 return bulkHandleInvoke(node, arg); 1222 return bulkHandleInvoke(node, arg);
1940 } 1223 }
1941 1224
1942 @override 1225 @override
1943 R visitIfNotNullDynamicPropertyInvoke( 1226 R visitIfNotNullDynamicPropertyInvoke(
1944 Send node, 1227 Send node, Node receiver, NodeList arguments, Selector selector, A arg) {
1945 Node receiver,
1946 NodeList arguments,
1947 Selector selector,
1948 A arg) {
1949 return bulkHandleInvoke(node, arg); 1228 return bulkHandleInvoke(node, arg);
1950 } 1229 }
1951 1230
1952 @override 1231 @override
1953 R visitDynamicTypeLiteralInvoke( 1232 R visitDynamicTypeLiteralInvoke(Send node, ConstantExpression constant,
1954 Send node, 1233 NodeList arguments, CallStructure callStructure, A arg) {
1955 ConstantExpression constant,
1956 NodeList arguments,
1957 CallStructure callStructure,
1958 A arg) {
1959 return bulkHandleInvoke(node, arg); 1234 return bulkHandleInvoke(node, arg);
1960 } 1235 }
1961 1236
1962 @override 1237 @override
1963 R visitExpressionInvoke( 1238 R visitExpressionInvoke(Send node, Node expression, NodeList arguments,
1964 Send node, 1239 CallStructure callStructure, A arg) {
1965 Node expression,
1966 NodeList arguments,
1967 CallStructure callStructure,
1968 A arg) {
1969 return bulkHandleInvoke(node, arg); 1240 return bulkHandleInvoke(node, arg);
1970 } 1241 }
1971 1242
1972 @override 1243 @override
1973 R visitLocalFunctionInvoke( 1244 R visitLocalFunctionInvoke(Send node, LocalFunctionElement function,
1974 Send node, 1245 NodeList arguments, CallStructure callStructure, A arg) {
1975 LocalFunctionElement function,
1976 NodeList arguments,
1977 CallStructure callStructure,
1978 A arg) {
1979 return bulkHandleInvoke(node, arg); 1246 return bulkHandleInvoke(node, arg);
1980 } 1247 }
1981 1248
1982 @override 1249 @override
1983 R visitLocalFunctionIncompatibleInvoke( 1250 R visitLocalFunctionIncompatibleInvoke(
1984 Send node, 1251 Send node,
1985 LocalFunctionElement function, 1252 LocalFunctionElement function,
1986 NodeList arguments, 1253 NodeList arguments,
1987 CallStructure callStructure, 1254 CallStructure callStructure,
1988 A arg) { 1255 A arg) {
1989 return bulkHandleInvoke(node, arg); 1256 return bulkHandleInvoke(node, arg);
1990 } 1257 }
1991 1258
1992 @override 1259 @override
1993 R visitLocalVariableInvoke( 1260 R visitLocalVariableInvoke(Send node, LocalVariableElement variable,
1994 Send node, 1261 NodeList arguments, CallStructure callStructure, A arg) {
1995 LocalVariableElement variable,
1996 NodeList arguments,
1997 CallStructure callStructure,
1998 A arg) {
1999 return bulkHandleInvoke(node, arg); 1262 return bulkHandleInvoke(node, arg);
2000 } 1263 }
2001 1264
2002 @override 1265 @override
2003 R visitParameterInvoke( 1266 R visitParameterInvoke(Send node, ParameterElement parameter,
2004 Send node, 1267 NodeList arguments, CallStructure callStructure, A arg) {
2005 ParameterElement parameter,
2006 NodeList arguments,
2007 CallStructure callStructure,
2008 A arg) {
2009 return bulkHandleInvoke(node, arg); 1268 return bulkHandleInvoke(node, arg);
2010 } 1269 }
2011 1270
2012 @override 1271 @override
2013 R visitStaticFieldInvoke( 1272 R visitStaticFieldInvoke(Send node, FieldElement field, NodeList arguments,
2014 Send node, 1273 CallStructure callStructure, A arg) {
2015 FieldElement field,
2016 NodeList arguments,
2017 CallStructure callStructure,
2018 A arg) {
2019 return bulkHandleInvoke(node, arg); 1274 return bulkHandleInvoke(node, arg);
2020 } 1275 }
2021 1276
2022 @override 1277 @override
2023 R visitStaticFunctionInvoke( 1278 R visitStaticFunctionInvoke(Send node, MethodElement function,
2024 Send node, 1279 NodeList arguments, CallStructure callStructure, A arg) {
2025 MethodElement function,
2026 NodeList arguments,
2027 CallStructure callStructure,
2028 A arg) {
2029 return bulkHandleInvoke(node, arg); 1280 return bulkHandleInvoke(node, arg);
2030 } 1281 }
2031 1282
2032 @override 1283 @override
2033 R visitStaticFunctionIncompatibleInvoke( 1284 R visitStaticFunctionIncompatibleInvoke(Send node, MethodElement function,
2034 Send node, 1285 NodeList arguments, CallStructure callStructure, A arg) {
2035 MethodElement function,
2036 NodeList arguments,
2037 CallStructure callStructure,
2038 A arg) {
2039 return bulkHandleInvoke(node, arg); 1286 return bulkHandleInvoke(node, arg);
2040 } 1287 }
2041 1288
2042 @override 1289 @override
2043 R visitStaticGetterInvoke( 1290 R visitStaticGetterInvoke(Send node, FunctionElement getter,
2044 Send node, 1291 NodeList arguments, CallStructure callStructure, A arg) {
2045 FunctionElement getter,
2046 NodeList arguments,
2047 CallStructure callStructure,
2048 A arg) {
2049 return bulkHandleInvoke(node, arg); 1292 return bulkHandleInvoke(node, arg);
2050 } 1293 }
2051 1294
2052 @override 1295 @override
2053 R visitSuperFieldInvoke( 1296 R visitSuperFieldInvoke(Send node, FieldElement field, NodeList arguments,
2054 Send node, 1297 CallStructure callStructure, A arg) {
2055 FieldElement field,
2056 NodeList arguments,
2057 CallStructure callStructure,
2058 A arg) {
2059 return bulkHandleInvoke(node, arg); 1298 return bulkHandleInvoke(node, arg);
2060 } 1299 }
2061 1300
2062 @override 1301 @override
2063 R visitSuperGetterInvoke( 1302 R visitSuperGetterInvoke(Send node, FunctionElement getter,
2064 Send node, 1303 NodeList arguments, CallStructure callStructure, A arg) {
2065 FunctionElement getter,
2066 NodeList arguments,
2067 CallStructure callStructure,
2068 A arg) {
2069 return bulkHandleInvoke(node, arg); 1304 return bulkHandleInvoke(node, arg);
2070 } 1305 }
2071 1306
2072 @override 1307 @override
2073 R visitSuperMethodInvoke( 1308 R visitSuperMethodInvoke(Send node, MethodElement method, NodeList arguments,
2074 Send node, 1309 CallStructure callStructure, A arg) {
2075 MethodElement method,
2076 NodeList arguments,
2077 CallStructure callStructure,
2078 A arg) {
2079 return bulkHandleInvoke(node, arg); 1310 return bulkHandleInvoke(node, arg);
2080 } 1311 }
2081 1312
2082 @override 1313 @override
2083 R visitSuperMethodIncompatibleInvoke( 1314 R visitSuperMethodIncompatibleInvoke(Send node, MethodElement method,
2084 Send node, 1315 NodeList arguments, CallStructure callStructure, A arg) {
2085 MethodElement method,
2086 NodeList arguments,
2087 CallStructure callStructure,
2088 A arg) {
2089 return bulkHandleInvoke(node, arg); 1316 return bulkHandleInvoke(node, arg);
2090 } 1317 }
2091 1318
2092 @override 1319 @override
2093 R visitThisInvoke( 1320 R visitThisInvoke(
2094 Send node, 1321 Send node, NodeList arguments, CallStructure callStructure, A arg) {
2095 NodeList arguments,
2096 CallStructure callStructure,
2097 A arg) {
2098 return bulkHandleInvoke(node, arg); 1322 return bulkHandleInvoke(node, arg);
2099 } 1323 }
2100 1324
2101 @override 1325 @override
2102 R visitThisPropertyInvoke( 1326 R visitThisPropertyInvoke(
2103 Send node, 1327 Send node, NodeList arguments, Selector selector, A arg) {
2104 NodeList arguments,
2105 Selector selector,
2106 A arg) {
2107 return bulkHandleInvoke(node, arg); 1328 return bulkHandleInvoke(node, arg);
2108 } 1329 }
2109 1330
2110 @override 1331 @override
2111 R visitTopLevelFieldInvoke( 1332 R visitTopLevelFieldInvoke(Send node, FieldElement field, NodeList arguments,
2112 Send node, 1333 CallStructure callStructure, A arg) {
2113 FieldElement field,
2114 NodeList arguments,
2115 CallStructure callStructure,
2116 A arg) {
2117 return bulkHandleInvoke(node, arg); 1334 return bulkHandleInvoke(node, arg);
2118 } 1335 }
2119 1336
2120 @override 1337 @override
2121 R visitTopLevelFunctionInvoke( 1338 R visitTopLevelFunctionInvoke(Send node, MethodElement function,
2122 Send node, 1339 NodeList arguments, CallStructure callStructure, A arg) {
2123 MethodElement function,
2124 NodeList arguments,
2125 CallStructure callStructure,
2126 A arg) {
2127 return bulkHandleInvoke(node, arg); 1340 return bulkHandleInvoke(node, arg);
2128 } 1341 }
2129 1342
2130 @override 1343 @override
2131 R visitTopLevelFunctionIncompatibleInvoke( 1344 R visitTopLevelFunctionIncompatibleInvoke(Send node, MethodElement function,
2132 Send node, 1345 NodeList arguments, CallStructure callStructure, A arg) {
2133 MethodElement function,
2134 NodeList arguments,
2135 CallStructure callStructure,
2136 A arg) {
2137 return bulkHandleInvoke(node, arg); 1346 return bulkHandleInvoke(node, arg);
2138 } 1347 }
2139 1348
2140 @override 1349 @override
2141 R visitTopLevelGetterInvoke( 1350 R visitTopLevelGetterInvoke(Send node, FunctionElement getter,
2142 Send node, 1351 NodeList arguments, CallStructure callStructure, A arg) {
2143 FunctionElement getter,
2144 NodeList arguments,
2145 CallStructure callStructure,
2146 A arg) {
2147 return bulkHandleInvoke(node, arg); 1352 return bulkHandleInvoke(node, arg);
2148 } 1353 }
2149 1354
2150 @override 1355 @override
2151 R visitTypeVariableTypeLiteralInvoke( 1356 R visitTypeVariableTypeLiteralInvoke(Send node, TypeVariableElement element,
2152 Send node, 1357 NodeList arguments, CallStructure callStructure, A arg) {
2153 TypeVariableElement element,
2154 NodeList arguments,
2155 CallStructure callStructure,
2156 A arg) {
2157 return bulkHandleInvoke(node, arg); 1358 return bulkHandleInvoke(node, arg);
2158 } 1359 }
2159 1360
2160 @override 1361 @override
2161 R visitTypedefTypeLiteralInvoke( 1362 R visitTypedefTypeLiteralInvoke(Send node, ConstantExpression constant,
2162 Send node, 1363 NodeList arguments, CallStructure callStructure, A arg) {
2163 ConstantExpression constant,
2164 NodeList arguments,
2165 CallStructure callStructure,
2166 A arg) {
2167 return bulkHandleInvoke(node, arg); 1364 return bulkHandleInvoke(node, arg);
2168 } 1365 }
2169 1366
2170 @override 1367 @override
2171 R visitConstantInvoke( 1368 R visitConstantInvoke(Send node, ConstantExpression constant,
2172 Send node, 1369 NodeList arguments, CallStructure callStructure, A arg) {
2173 ConstantExpression constant,
2174 NodeList arguments,
2175 CallStructure callStructure,
2176 A arg) {
2177 return bulkHandleInvoke(node, arg); 1370 return bulkHandleInvoke(node, arg);
2178 } 1371 }
2179 1372
2180 @override 1373 @override
2181 R visitUnresolvedInvoke( 1374 R visitUnresolvedInvoke(Send node, Element element, NodeList arguments,
2182 Send node, 1375 Selector selector, A arg) {
2183 Element element,
2184 NodeList arguments,
2185 Selector selector,
2186 A arg) {
2187 return bulkHandleInvoke(node, arg); 1376 return bulkHandleInvoke(node, arg);
2188 } 1377 }
2189 1378
2190 @override 1379 @override
2191 R visitUnresolvedSuperInvoke( 1380 R visitUnresolvedSuperInvoke(Send node, Element function, NodeList arguments,
2192 Send node, 1381 Selector selector, A arg) {
2193 Element function,
2194 NodeList arguments,
2195 Selector selector,
2196 A arg) {
2197 return bulkHandleInvoke(node, arg); 1382 return bulkHandleInvoke(node, arg);
2198 } 1383 }
2199 1384
2200 @override 1385 @override
2201 R visitStaticSetterInvoke( 1386 R visitStaticSetterInvoke(Send node, FunctionElement setter,
2202 Send node, 1387 NodeList arguments, CallStructure callStructure, A arg) {
2203 FunctionElement setter,
2204 NodeList arguments,
2205 CallStructure callStructure,
2206 A arg) {
2207 return bulkHandleInvoke(node, arg); 1388 return bulkHandleInvoke(node, arg);
2208 } 1389 }
2209 1390
2210 @override 1391 @override
2211 R visitSuperSetterInvoke( 1392 R visitSuperSetterInvoke(Send node, FunctionElement setter,
2212 Send node, 1393 NodeList arguments, CallStructure callStructure, A arg) {
2213 FunctionElement setter,
2214 NodeList arguments,
2215 CallStructure callStructure,
2216 A arg) {
2217 return bulkHandleInvoke(node, arg); 1394 return bulkHandleInvoke(node, arg);
2218 } 1395 }
2219 1396
2220 @override 1397 @override
2221 R visitTopLevelSetterInvoke( 1398 R visitTopLevelSetterInvoke(Send node, FunctionElement setter,
2222 Send node, 1399 NodeList arguments, CallStructure callStructure, A arg) {
2223 FunctionElement setter,
2224 NodeList arguments,
2225 CallStructure callStructure,
2226 A arg) {
2227 return bulkHandleInvoke(node, arg); 1400 return bulkHandleInvoke(node, arg);
2228 } 1401 }
2229 } 1402 }
2230 1403
2231 /// Mixin that implements all `visitXGet` methods of [SemanticSendVisitor] by 1404 /// Mixin that implements all `visitXGet` methods of [SemanticSendVisitor] by
2232 /// delegating to a bulk handler. 1405 /// delegating to a bulk handler.
2233 /// 1406 ///
2234 /// Use this mixin to provide a trivial implementation for all `visitXGet` 1407 /// Use this mixin to provide a trivial implementation for all `visitXGet`
2235 /// methods. 1408 /// methods.
2236 abstract class GetBulkMixin<R, A> 1409 abstract class GetBulkMixin<R, A>
2237 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 1410 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
2238
2239 R bulkHandleGet(Node node, A arg) { 1411 R bulkHandleGet(Node node, A arg) {
2240 return bulkHandleNode(node, "Read `#` unhandled.", arg); 1412 return bulkHandleNode(node, "Read `#` unhandled.", arg);
2241 } 1413 }
2242 1414
2243 @override 1415 @override
2244 R visitClassTypeLiteralGet( 1416 R visitClassTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
2245 Send node,
2246 ConstantExpression constant,
2247 A arg) {
2248 return bulkHandleGet(node, arg); 1417 return bulkHandleGet(node, arg);
2249 } 1418 }
2250 1419
2251 @override 1420 @override
2252 R visitDynamicPropertyGet( 1421 R visitDynamicPropertyGet(Send node, Node receiver, Name name, A arg) {
2253 Send node,
2254 Node receiver,
2255 Name name,
2256 A arg) {
2257 return bulkHandleGet(node, arg); 1422 return bulkHandleGet(node, arg);
2258 } 1423 }
2259 1424
2260 @override 1425 @override
2261 R visitIfNotNullDynamicPropertyGet( 1426 R visitIfNotNullDynamicPropertyGet(
2262 Send node, 1427 Send node, Node receiver, Name name, A arg) {
2263 Node receiver,
2264 Name name,
2265 A arg) {
2266 return bulkHandleGet(node, arg); 1428 return bulkHandleGet(node, arg);
2267 } 1429 }
2268 1430
2269 @override 1431 @override
2270 R visitDynamicTypeLiteralGet( 1432 R visitDynamicTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
2271 Send node,
2272 ConstantExpression constant,
2273 A arg) {
2274 return bulkHandleGet(node, arg); 1433 return bulkHandleGet(node, arg);
2275 } 1434 }
2276 1435
2277 @override 1436 @override
2278 R visitLocalFunctionGet( 1437 R visitLocalFunctionGet(Send node, LocalFunctionElement function, A arg) {
2279 Send node,
2280 LocalFunctionElement function,
2281 A arg) {
2282 return bulkHandleGet(node, arg); 1438 return bulkHandleGet(node, arg);
2283 } 1439 }
2284 1440
2285 @override 1441 @override
2286 R visitLocalVariableGet( 1442 R visitLocalVariableGet(Send node, LocalVariableElement variable, A arg) {
2287 Send node,
2288 LocalVariableElement variable,
2289 A arg) {
2290 return bulkHandleGet(node, arg); 1443 return bulkHandleGet(node, arg);
2291 } 1444 }
2292 1445
2293 @override 1446 @override
2294 R visitParameterGet( 1447 R visitParameterGet(Send node, ParameterElement parameter, A arg) {
2295 Send node,
2296 ParameterElement parameter,
2297 A arg) {
2298 return bulkHandleGet(node, arg); 1448 return bulkHandleGet(node, arg);
2299 } 1449 }
2300 1450
2301 @override 1451 @override
2302 R visitStaticFieldGet( 1452 R visitStaticFieldGet(Send node, FieldElement field, A arg) {
2303 Send node,
2304 FieldElement field,
2305 A arg) {
2306 return bulkHandleGet(node, arg); 1453 return bulkHandleGet(node, arg);
2307 } 1454 }
2308 1455
2309 @override 1456 @override
2310 R visitStaticFunctionGet( 1457 R visitStaticFunctionGet(Send node, MethodElement function, A arg) {
2311 Send node,
2312 MethodElement function,
2313 A arg) {
2314 return bulkHandleGet(node, arg); 1458 return bulkHandleGet(node, arg);
2315 } 1459 }
2316 1460
2317 @override 1461 @override
2318 R visitStaticGetterGet( 1462 R visitStaticGetterGet(Send node, FunctionElement getter, A arg) {
2319 Send node,
2320 FunctionElement getter,
2321 A arg) {
2322 return bulkHandleGet(node, arg); 1463 return bulkHandleGet(node, arg);
2323 } 1464 }
2324 1465
2325 @override 1466 @override
2326 R visitSuperFieldGet( 1467 R visitSuperFieldGet(Send node, FieldElement field, A arg) {
2327 Send node,
2328 FieldElement field,
2329 A arg) {
2330 return bulkHandleGet(node, arg); 1468 return bulkHandleGet(node, arg);
2331 } 1469 }
2332 1470
2333 @override 1471 @override
2334 R visitSuperGetterGet( 1472 R visitSuperGetterGet(Send node, FunctionElement getter, A arg) {
2335 Send node,
2336 FunctionElement getter,
2337 A arg) {
2338 return bulkHandleGet(node, arg); 1473 return bulkHandleGet(node, arg);
2339 } 1474 }
2340 1475
2341 @override 1476 @override
2342 R visitSuperMethodGet( 1477 R visitSuperMethodGet(Send node, MethodElement method, A arg) {
2343 Send node,
2344 MethodElement method,
2345 A arg) {
2346 return bulkHandleGet(node, arg); 1478 return bulkHandleGet(node, arg);
2347 } 1479 }
2348 1480
2349 @override 1481 @override
2350 R visitThisGet(Identifier node, A arg) { 1482 R visitThisGet(Identifier node, A arg) {
2351 return bulkHandleGet(node, arg); 1483 return bulkHandleGet(node, arg);
2352 } 1484 }
2353 1485
2354 @override 1486 @override
2355 R visitThisPropertyGet( 1487 R visitThisPropertyGet(Send node, Name name, A arg) {
2356 Send node,
2357 Name name,
2358 A arg) {
2359 return bulkHandleGet(node, arg); 1488 return bulkHandleGet(node, arg);
2360 } 1489 }
2361 1490
2362 @override 1491 @override
2363 R visitTopLevelFieldGet( 1492 R visitTopLevelFieldGet(Send node, FieldElement field, A arg) {
2364 Send node,
2365 FieldElement field,
2366 A arg) {
2367 return bulkHandleGet(node, arg); 1493 return bulkHandleGet(node, arg);
2368 } 1494 }
2369 1495
2370 @override 1496 @override
2371 R visitTopLevelFunctionGet( 1497 R visitTopLevelFunctionGet(Send node, MethodElement function, A arg) {
2372 Send node,
2373 MethodElement function,
2374 A arg) {
2375 return bulkHandleGet(node, arg); 1498 return bulkHandleGet(node, arg);
2376 } 1499 }
2377 1500
2378 @override 1501 @override
2379 R visitTopLevelGetterGet( 1502 R visitTopLevelGetterGet(Send node, FunctionElement getter, A arg) {
2380 Send node,
2381 FunctionElement getter,
2382 A arg) {
2383 return bulkHandleGet(node, arg); 1503 return bulkHandleGet(node, arg);
2384 } 1504 }
2385 1505
2386 @override 1506 @override
2387 R visitTypeVariableTypeLiteralGet( 1507 R visitTypeVariableTypeLiteralGet(
2388 Send node, 1508 Send node, TypeVariableElement element, A arg) {
2389 TypeVariableElement element,
2390 A arg) {
2391 return bulkHandleGet(node, arg); 1509 return bulkHandleGet(node, arg);
2392 } 1510 }
2393 1511
2394 @override 1512 @override
2395 R visitTypedefTypeLiteralGet( 1513 R visitTypedefTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
2396 Send node,
2397 ConstantExpression constant,
2398 A arg) {
2399 return bulkHandleGet(node, arg); 1514 return bulkHandleGet(node, arg);
2400 } 1515 }
2401 1516
2402 @override 1517 @override
2403 R visitConstantGet( 1518 R visitConstantGet(Send node, ConstantExpression constant, A arg) {
2404 Send node,
2405 ConstantExpression constant,
2406 A arg) {
2407 return bulkHandleGet(node, arg); 1519 return bulkHandleGet(node, arg);
2408 } 1520 }
2409 1521
2410 @override 1522 @override
2411 R visitUnresolvedGet( 1523 R visitUnresolvedGet(Send node, Element element, A arg) {
2412 Send node,
2413 Element element,
2414 A arg) {
2415 return bulkHandleGet(node, arg); 1524 return bulkHandleGet(node, arg);
2416 } 1525 }
2417 1526
2418 @override 1527 @override
2419 R visitUnresolvedSuperGet( 1528 R visitUnresolvedSuperGet(Send node, Element element, A arg) {
2420 Send node,
2421 Element element,
2422 A arg) {
2423 return bulkHandleGet(node, arg); 1529 return bulkHandleGet(node, arg);
2424 } 1530 }
2425 1531
2426 @override 1532 @override
2427 R visitStaticSetterGet( 1533 R visitStaticSetterGet(Send node, FunctionElement setter, A arg) {
2428 Send node,
2429 FunctionElement setter,
2430 A arg) {
2431 return bulkHandleGet(node, arg); 1534 return bulkHandleGet(node, arg);
2432 } 1535 }
2433 1536
2434 @override 1537 @override
2435 R visitSuperSetterGet( 1538 R visitSuperSetterGet(Send node, FunctionElement setter, A arg) {
2436 Send node,
2437 FunctionElement setter,
2438 A arg) {
2439 return bulkHandleGet(node, arg); 1539 return bulkHandleGet(node, arg);
2440 } 1540 }
2441 1541
2442 @override 1542 @override
2443 R visitTopLevelSetterGet( 1543 R visitTopLevelSetterGet(Send node, FunctionElement setter, A arg) {
2444 Send node,
2445 FunctionElement setter,
2446 A arg) {
2447 return bulkHandleGet(node, arg); 1544 return bulkHandleGet(node, arg);
2448 } 1545 }
2449 } 1546 }
2450 1547
2451 /// Mixin that implements all `visitXSet` methods of [SemanticSendVisitor] by 1548 /// Mixin that implements all `visitXSet` methods of [SemanticSendVisitor] by
2452 /// delegating to a bulk handler. 1549 /// delegating to a bulk handler.
2453 /// 1550 ///
2454 /// Use this mixin to provide a trivial implementation for all `visitXSet` 1551 /// Use this mixin to provide a trivial implementation for all `visitXSet`
2455 /// methods. 1552 /// methods.
2456 abstract class SetBulkMixin<R, A> 1553 abstract class SetBulkMixin<R, A>
2457 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 1554 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
2458
2459 R bulkHandleSet(Send node, A arg) { 1555 R bulkHandleSet(Send node, A arg) {
2460 return bulkHandleNode(node, "Assignment `#` unhandled.", arg); 1556 return bulkHandleNode(node, "Assignment `#` unhandled.", arg);
2461 } 1557 }
2462 1558
2463 @override 1559 @override
2464 R visitDynamicPropertySet( 1560 R visitDynamicPropertySet(
2465 SendSet node, 1561 SendSet node, Node receiver, Name name, Node rhs, A arg) {
2466 Node receiver,
2467 Name name,
2468 Node rhs,
2469 A arg) {
2470 return bulkHandleSet(node, arg); 1562 return bulkHandleSet(node, arg);
2471 } 1563 }
2472 1564
2473 @override 1565 @override
2474 R visitIfNotNullDynamicPropertySet( 1566 R visitIfNotNullDynamicPropertySet(
2475 SendSet node, 1567 SendSet node, Node receiver, Name name, Node rhs, A arg) {
2476 Node receiver,
2477 Name name,
2478 Node rhs,
2479 A arg) {
2480 return bulkHandleSet(node, arg); 1568 return bulkHandleSet(node, arg);
2481 } 1569 }
2482 1570
2483 @override 1571 @override
2484 R visitLocalVariableSet( 1572 R visitLocalVariableSet(
2485 SendSet node, 1573 SendSet node, LocalVariableElement variable, Node rhs, A arg) {
2486 LocalVariableElement variable,
2487 Node rhs,
2488 A arg) {
2489 return bulkHandleSet(node, arg); 1574 return bulkHandleSet(node, arg);
2490 } 1575 }
2491 1576
2492 @override 1577 @override
2493 R visitParameterSet( 1578 R visitParameterSet(
2494 SendSet node, 1579 SendSet node, ParameterElement parameter, Node rhs, A arg) {
2495 ParameterElement parameter,
2496 Node rhs,
2497 A arg) {
2498 return bulkHandleSet(node, arg); 1580 return bulkHandleSet(node, arg);
2499 } 1581 }
2500 1582
2501 @override 1583 @override
2502 R visitStaticFieldSet( 1584 R visitStaticFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
2503 SendSet node,
2504 FieldElement field,
2505 Node rhs,
2506 A arg) {
2507 return bulkHandleSet(node, arg); 1585 return bulkHandleSet(node, arg);
2508 } 1586 }
2509 1587
2510 @override 1588 @override
2511 R visitStaticSetterSet( 1589 R visitStaticSetterSet(
2512 SendSet node, 1590 SendSet node, FunctionElement setter, Node rhs, A arg) {
2513 FunctionElement setter,
2514 Node rhs,
2515 A arg) {
2516 return bulkHandleSet(node, arg); 1591 return bulkHandleSet(node, arg);
2517 } 1592 }
2518 1593
2519 @override 1594 @override
2520 R visitSuperFieldSet( 1595 R visitSuperFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
2521 SendSet node,
2522 FieldElement field,
2523 Node rhs,
2524 A arg) {
2525 return bulkHandleSet(node, arg); 1596 return bulkHandleSet(node, arg);
2526 } 1597 }
2527 1598
2528 @override 1599 @override
2529 R visitSuperSetterSet( 1600 R visitSuperSetterSet(SendSet node, FunctionElement setter, Node rhs, A arg) {
2530 SendSet node,
2531 FunctionElement setter,
2532 Node rhs,
2533 A arg) {
2534 return bulkHandleSet(node, arg); 1601 return bulkHandleSet(node, arg);
2535 } 1602 }
2536 1603
2537 @override 1604 @override
2538 R visitThisPropertySet( 1605 R visitThisPropertySet(SendSet node, Name name, Node rhs, A arg) {
2539 SendSet node,
2540 Name name,
2541 Node rhs,
2542 A arg) {
2543 return bulkHandleSet(node, arg); 1606 return bulkHandleSet(node, arg);
2544 } 1607 }
2545 1608
2546 @override 1609 @override
2547 R visitTopLevelFieldSet( 1610 R visitTopLevelFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
2548 SendSet node,
2549 FieldElement field,
2550 Node rhs,
2551 A arg) {
2552 return bulkHandleSet(node, arg); 1611 return bulkHandleSet(node, arg);
2553 } 1612 }
2554 1613
2555 @override 1614 @override
2556 R visitTopLevelSetterSet( 1615 R visitTopLevelSetterSet(
2557 SendSet node, 1616 SendSet node, FunctionElement setter, Node rhs, A arg) {
2558 FunctionElement setter,
2559 Node rhs,
2560 A arg) {
2561 return bulkHandleSet(node, arg); 1617 return bulkHandleSet(node, arg);
2562 } 1618 }
2563 1619
2564 @override 1620 @override
2565 R visitClassTypeLiteralSet( 1621 R visitClassTypeLiteralSet(
2566 SendSet node, 1622 SendSet node, ConstantExpression constant, Node rhs, A arg) {
2567 ConstantExpression constant,
2568 Node rhs,
2569 A arg) {
2570 return bulkHandleSet(node, arg); 1623 return bulkHandleSet(node, arg);
2571 } 1624 }
2572 1625
2573 @override 1626 @override
2574 R visitDynamicTypeLiteralSet( 1627 R visitDynamicTypeLiteralSet(
2575 SendSet node, 1628 SendSet node, ConstantExpression constant, Node rhs, A arg) {
2576 ConstantExpression constant,
2577 Node rhs,
2578 A arg) {
2579 return bulkHandleSet(node, arg); 1629 return bulkHandleSet(node, arg);
2580 } 1630 }
2581 1631
2582 @override 1632 @override
2583 R visitFinalLocalVariableSet( 1633 R visitFinalLocalVariableSet(
2584 SendSet node, 1634 SendSet node, LocalVariableElement variable, Node rhs, A arg) {
2585 LocalVariableElement variable,
2586 Node rhs,
2587 A arg) {
2588 return bulkHandleSet(node, arg); 1635 return bulkHandleSet(node, arg);
2589 } 1636 }
2590 1637
2591 @override 1638 @override
2592 R visitFinalParameterSet( 1639 R visitFinalParameterSet(
2593 SendSet node, 1640 SendSet node, ParameterElement parameter, Node rhs, A arg) {
2594 ParameterElement parameter,
2595 Node rhs,
2596 A arg) {
2597 return bulkHandleSet(node, arg); 1641 return bulkHandleSet(node, arg);
2598 } 1642 }
2599 1643
2600 @override 1644 @override
2601 R visitFinalStaticFieldSet( 1645 R visitFinalStaticFieldSet(
2602 SendSet node, 1646 SendSet node, FieldElement field, Node rhs, A arg) {
2603 FieldElement field,
2604 Node rhs,
2605 A arg) {
2606 return bulkHandleSet(node, arg); 1647 return bulkHandleSet(node, arg);
2607 } 1648 }
2608 1649
2609 @override 1650 @override
2610 R visitFinalSuperFieldSet( 1651 R visitFinalSuperFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
2611 SendSet node,
2612 FieldElement field,
2613 Node rhs,
2614 A arg) {
2615 return bulkHandleSet(node, arg); 1652 return bulkHandleSet(node, arg);
2616 } 1653 }
2617 1654
2618 @override 1655 @override
2619 R visitFinalTopLevelFieldSet( 1656 R visitFinalTopLevelFieldSet(
2620 SendSet node, 1657 SendSet node, FieldElement field, Node rhs, A arg) {
2621 FieldElement field,
2622 Node rhs,
2623 A arg) {
2624 return bulkHandleSet(node, arg); 1658 return bulkHandleSet(node, arg);
2625 } 1659 }
2626 1660
2627 @override 1661 @override
2628 R visitLocalFunctionSet( 1662 R visitLocalFunctionSet(
2629 SendSet node, 1663 SendSet node, LocalFunctionElement function, Node rhs, A arg) {
2630 LocalFunctionElement function,
2631 Node rhs,
2632 A arg) {
2633 return bulkHandleSet(node, arg); 1664 return bulkHandleSet(node, arg);
2634 } 1665 }
2635 1666
2636 @override 1667 @override
2637 R visitStaticFunctionSet( 1668 R visitStaticFunctionSet(Send node, MethodElement function, Node rhs, A arg) {
2638 Send node,
2639 MethodElement function,
2640 Node rhs,
2641 A arg) {
2642 return bulkHandleSet(node, arg); 1669 return bulkHandleSet(node, arg);
2643 } 1670 }
2644 1671
2645 @override 1672 @override
2646 R visitStaticGetterSet( 1673 R visitStaticGetterSet(
2647 SendSet node, 1674 SendSet node, FunctionElement getter, Node rhs, A arg) {
2648 FunctionElement getter,
2649 Node rhs,
2650 A arg) {
2651 return bulkHandleSet(node, arg); 1675 return bulkHandleSet(node, arg);
2652 } 1676 }
2653 1677
2654 @override 1678 @override
2655 R visitSuperGetterSet( 1679 R visitSuperGetterSet(SendSet node, FunctionElement getter, Node rhs, A arg) {
2656 SendSet node,
2657 FunctionElement getter,
2658 Node rhs,
2659 A arg) {
2660 return bulkHandleSet(node, arg); 1680 return bulkHandleSet(node, arg);
2661 } 1681 }
2662 1682
2663 @override 1683 @override
2664 R visitSuperMethodSet( 1684 R visitSuperMethodSet(Send node, MethodElement method, Node rhs, A arg) {
2665 Send node,
2666 MethodElement method,
2667 Node rhs,
2668 A arg) {
2669 return bulkHandleSet(node, arg); 1685 return bulkHandleSet(node, arg);
2670 } 1686 }
2671 1687
2672 @override 1688 @override
2673 R visitTopLevelFunctionSet( 1689 R visitTopLevelFunctionSet(
2674 Send node, 1690 Send node, MethodElement function, Node rhs, A arg) {
2675 MethodElement function,
2676 Node rhs,
2677 A arg) {
2678 return bulkHandleSet(node, arg); 1691 return bulkHandleSet(node, arg);
2679 } 1692 }
2680 1693
2681 @override 1694 @override
2682 R visitTopLevelGetterSet( 1695 R visitTopLevelGetterSet(
2683 SendSet node, 1696 SendSet node, FunctionElement getter, Node rhs, A arg) {
2684 FunctionElement getter,
2685 Node rhs,
2686 A arg) {
2687 return bulkHandleSet(node, arg); 1697 return bulkHandleSet(node, arg);
2688 } 1698 }
2689 1699
2690 @override 1700 @override
2691 R visitTypeVariableTypeLiteralSet( 1701 R visitTypeVariableTypeLiteralSet(
2692 SendSet node, 1702 SendSet node, TypeVariableElement element, Node rhs, A arg) {
2693 TypeVariableElement element,
2694 Node rhs,
2695 A arg) {
2696 return bulkHandleSet(node, arg); 1703 return bulkHandleSet(node, arg);
2697 } 1704 }
2698 1705
2699 @override 1706 @override
2700 R visitTypedefTypeLiteralSet( 1707 R visitTypedefTypeLiteralSet(
2701 SendSet node, 1708 SendSet node, ConstantExpression constant, Node rhs, A arg) {
2702 ConstantExpression constant,
2703 Node rhs,
2704 A arg) {
2705 return bulkHandleSet(node, arg); 1709 return bulkHandleSet(node, arg);
2706 } 1710 }
2707 1711
2708 @override 1712 @override
2709 R visitUnresolvedSet( 1713 R visitUnresolvedSet(Send node, Element element, Node rhs, A arg) {
2710 Send node,
2711 Element element,
2712 Node rhs,
2713 A arg) {
2714 return bulkHandleSet(node, arg); 1714 return bulkHandleSet(node, arg);
2715 } 1715 }
2716 1716
2717 @override 1717 @override
2718 R visitUnresolvedSuperSet( 1718 R visitUnresolvedSuperSet(Send node, Element element, Node rhs, A arg) {
2719 Send node,
2720 Element element,
2721 Node rhs,
2722 A arg) {
2723 return bulkHandleSet(node, arg); 1719 return bulkHandleSet(node, arg);
2724 } 1720 }
2725 } 1721 }
2726 1722
2727 /// Mixin that implements all `visitXIndexSet` methods of [SemanticSendVisitor] 1723 /// Mixin that implements all `visitXIndexSet` methods of [SemanticSendVisitor]
2728 /// by delegating to a bulk handler. 1724 /// by delegating to a bulk handler.
2729 /// 1725 ///
2730 /// Use this mixin to provide a trivial implementation for all `visitXIndexSet` 1726 /// Use this mixin to provide a trivial implementation for all `visitXIndexSet`
2731 /// methods. 1727 /// methods.
2732 abstract class IndexSetBulkMixin<R, A> 1728 abstract class IndexSetBulkMixin<R, A>
2733 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 1729 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
2734
2735 R bulkHandleIndexSet(Send node, A arg) { 1730 R bulkHandleIndexSet(Send node, A arg) {
2736 return bulkHandleNode(node, "Index set expression `#` unhandled.", arg); 1731 return bulkHandleNode(node, "Index set expression `#` unhandled.", arg);
2737 } 1732 }
2738 1733
2739 @override 1734 @override
2740 R visitCompoundIndexSet( 1735 R visitCompoundIndexSet(SendSet node, Node receiver, Node index,
2741 SendSet node, 1736 AssignmentOperator operator, Node rhs, A arg) {
2742 Node receiver,
2743 Node index,
2744 AssignmentOperator operator,
2745 Node rhs,
2746 A arg) {
2747 return bulkHandleIndexSet(node, arg); 1737 return bulkHandleIndexSet(node, arg);
2748 } 1738 }
2749 1739
2750 @override 1740 @override
2751 R visitIndexSet( 1741 R visitIndexSet(SendSet node, Node receiver, Node index, Node rhs, A arg) {
2752 SendSet node,
2753 Node receiver,
2754 Node index,
2755 Node rhs,
2756 A arg) {
2757 return bulkHandleIndexSet(node, arg); 1742 return bulkHandleIndexSet(node, arg);
2758 } 1743 }
2759 1744
2760 @override 1745 @override
2761 R visitSuperCompoundIndexSet( 1746 R visitSuperCompoundIndexSet(
2762 SendSet node, 1747 SendSet node,
2763 FunctionElement getter, 1748 FunctionElement getter,
2764 FunctionElement setter, 1749 FunctionElement setter,
2765 Node index, 1750 Node index,
2766 AssignmentOperator operator, 1751 AssignmentOperator operator,
(...skipping 20 matching lines...) Expand all
2787 MethodElement getter, 1772 MethodElement getter,
2788 Element element, 1773 Element element,
2789 Node index, 1774 Node index,
2790 AssignmentOperator operator, 1775 AssignmentOperator operator,
2791 Node rhs, 1776 Node rhs,
2792 A arg) { 1777 A arg) {
2793 return bulkHandleIndexSet(node, arg); 1778 return bulkHandleIndexSet(node, arg);
2794 } 1779 }
2795 1780
2796 @override 1781 @override
2797 R visitUnresolvedSuperCompoundIndexSet( 1782 R visitUnresolvedSuperCompoundIndexSet(SendSet node, Element element,
2798 SendSet node, 1783 Node index, AssignmentOperator operator, Node rhs, A arg) {
2799 Element element,
2800 Node index,
2801 AssignmentOperator operator,
2802 Node rhs,
2803 A arg) {
2804 return bulkHandleIndexSet(node, arg); 1784 return bulkHandleIndexSet(node, arg);
2805 } 1785 }
2806 1786
2807 @override 1787 @override
2808 R visitSuperIndexSet( 1788 R visitSuperIndexSet(
2809 SendSet node, 1789 SendSet node, FunctionElement function, Node index, Node rhs, A arg) {
2810 FunctionElement function,
2811 Node index,
2812 Node rhs,
2813 A arg) {
2814 return bulkHandleIndexSet(node, arg); 1790 return bulkHandleIndexSet(node, arg);
2815 } 1791 }
2816 1792
2817 @override 1793 @override
2818 R visitUnresolvedSuperIndexSet( 1794 R visitUnresolvedSuperIndexSet(
2819 SendSet node, 1795 SendSet node, Element element, Node index, Node rhs, A arg) {
2820 Element element,
2821 Node index,
2822 Node rhs,
2823 A arg) {
2824 return bulkHandleIndexSet(node, arg); 1796 return bulkHandleIndexSet(node, arg);
2825 } 1797 }
2826 } 1798 }
2827 1799
2828 /// Mixin that implements all binary visitor methods in [SemanticSendVisitor] by 1800 /// Mixin that implements all binary visitor methods in [SemanticSendVisitor] by
2829 /// delegating to a bulk handler. 1801 /// delegating to a bulk handler.
2830 /// 1802 ///
2831 /// Use this mixin to provide a trivial implementation for all binary visitor 1803 /// Use this mixin to provide a trivial implementation for all binary visitor
2832 /// methods. 1804 /// methods.
2833 abstract class BinaryBulkMixin<R, A> 1805 abstract class BinaryBulkMixin<R, A>
2834 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 1806 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
2835
2836 R bulkHandleBinary(Send node, A arg) { 1807 R bulkHandleBinary(Send node, A arg) {
2837 return bulkHandleNode(node, "Binary expression `#` unhandled.", arg); 1808 return bulkHandleNode(node, "Binary expression `#` unhandled.", arg);
2838 } 1809 }
2839 1810
2840 @override 1811 @override
2841 R visitBinary( 1812 R visitBinary(
2842 Send node, 1813 Send node, Node left, BinaryOperator operator, Node right, A arg) {
2843 Node left,
2844 BinaryOperator operator,
2845 Node right,
2846 A arg) {
2847 return bulkHandleBinary(node, arg); 1814 return bulkHandleBinary(node, arg);
2848 } 1815 }
2849 1816
2850 @override 1817 @override
2851 R visitEquals( 1818 R visitEquals(Send node, Node left, Node right, A arg) {
2852 Send node,
2853 Node left,
2854 Node right,
2855 A arg) {
2856 return bulkHandleBinary(node, arg); 1819 return bulkHandleBinary(node, arg);
2857 } 1820 }
2858 1821
2859 @override 1822 @override
2860 R visitNotEquals( 1823 R visitNotEquals(Send node, Node left, Node right, A arg) {
2861 Send node,
2862 Node left,
2863 Node right,
2864 A arg) {
2865 return bulkHandleBinary(node, arg); 1824 return bulkHandleBinary(node, arg);
2866 } 1825 }
2867 1826
2868 @override 1827 @override
2869 R visitIndex( 1828 R visitIndex(Send node, Node receiver, Node index, A arg) {
2870 Send node,
2871 Node receiver,
2872 Node index,
2873 A arg) {
2874 return bulkHandleBinary(node, arg); 1829 return bulkHandleBinary(node, arg);
2875 } 1830 }
2876 1831
2877 @override 1832 @override
2878 R visitSuperBinary( 1833 R visitSuperBinary(Send node, FunctionElement function,
2879 Send node, 1834 BinaryOperator operator, Node argument, A arg) {
2880 FunctionElement function,
2881 BinaryOperator operator,
2882 Node argument,
2883 A arg) {
2884 return bulkHandleBinary(node, arg); 1835 return bulkHandleBinary(node, arg);
2885 } 1836 }
2886 1837
2887 @override 1838 @override
2888 R visitSuperEquals( 1839 R visitSuperEquals(
2889 Send node, 1840 Send node, FunctionElement function, Node argument, A arg) {
2890 FunctionElement function,
2891 Node argument,
2892 A arg) {
2893 return bulkHandleBinary(node, arg); 1841 return bulkHandleBinary(node, arg);
2894 } 1842 }
2895 1843
2896 @override 1844 @override
2897 R visitSuperNotEquals( 1845 R visitSuperNotEquals(
2898 Send node, 1846 Send node, FunctionElement function, Node argument, A arg) {
2899 FunctionElement function,
2900 Node argument,
2901 A arg) {
2902 return bulkHandleBinary(node, arg); 1847 return bulkHandleBinary(node, arg);
2903 } 1848 }
2904 1849
2905 @override 1850 @override
2906 R visitSuperIndex( 1851 R visitSuperIndex(Send node, FunctionElement function, Node index, A arg) {
2907 Send node,
2908 FunctionElement function,
2909 Node index,
2910 A arg) {
2911 return bulkHandleBinary(node, arg); 1852 return bulkHandleBinary(node, arg);
2912 } 1853 }
2913 1854
2914 @override 1855 @override
2915 R visitUnresolvedSuperBinary( 1856 R visitUnresolvedSuperBinary(Send node, FunctionElement function,
2916 Send node, 1857 BinaryOperator operator, Node argument, A arg) {
2917 FunctionElement function,
2918 BinaryOperator operator,
2919 Node argument,
2920 A arg) {
2921 return bulkHandleBinary(node, arg); 1858 return bulkHandleBinary(node, arg);
2922 } 1859 }
2923 1860
2924 @override 1861 @override
2925 R visitUnresolvedSuperInvoke( 1862 R visitUnresolvedSuperInvoke(Send node, Element function, NodeList arguments,
2926 Send node, 1863 Selector selector, A arg) {
2927 Element function,
2928 NodeList arguments,
2929 Selector selector,
2930 A arg) {
2931 return bulkHandleBinary(node, arg); 1864 return bulkHandleBinary(node, arg);
2932 } 1865 }
2933 1866
2934 @override 1867 @override
2935 R visitUnresolvedSuperIndex( 1868 R visitUnresolvedSuperIndex(
2936 Send node, 1869 Send node, FunctionElement function, Node index, A arg) {
2937 FunctionElement function,
2938 Node index,
2939 A arg) {
2940 return bulkHandleBinary(node, arg); 1870 return bulkHandleBinary(node, arg);
2941 } 1871 }
2942 } 1872 }
2943 1873
2944 /// Mixin that implements all unary visitor methods in [SemanticSendVisitor] by 1874 /// Mixin that implements all unary visitor methods in [SemanticSendVisitor] by
2945 /// delegating to a bulk handler. 1875 /// delegating to a bulk handler.
2946 /// 1876 ///
2947 /// Use this mixin to provide a trivial implementation for all unary visitor 1877 /// Use this mixin to provide a trivial implementation for all unary visitor
2948 /// methods. 1878 /// methods.
2949 abstract class UnaryBulkMixin<R, A> 1879 abstract class UnaryBulkMixin<R, A>
2950 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 1880 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
2951
2952 R bulkHandleUnary(Send node, A arg) { 1881 R bulkHandleUnary(Send node, A arg) {
2953 return bulkHandleNode(node, "Unary expression `#` unhandled.", arg); 1882 return bulkHandleNode(node, "Unary expression `#` unhandled.", arg);
2954 } 1883 }
2955 1884
2956 @override 1885 @override
2957 R visitNot( 1886 R visitNot(Send node, Node expression, A arg) {
2958 Send node,
2959 Node expression,
2960 A arg) {
2961 return bulkHandleUnary(node, arg); 1887 return bulkHandleUnary(node, arg);
2962 } 1888 }
2963 1889
2964 @override 1890 @override
2965 R visitSuperUnary( 1891 R visitSuperUnary(
2966 Send node, 1892 Send node, UnaryOperator operator, FunctionElement function, A arg) {
2967 UnaryOperator operator,
2968 FunctionElement function,
2969 A arg) {
2970 return bulkHandleUnary(node, arg); 1893 return bulkHandleUnary(node, arg);
2971 } 1894 }
2972 1895
2973 @override 1896 @override
2974 R visitUnary( 1897 R visitUnary(Send node, UnaryOperator operator, Node expression, A arg) {
2975 Send node,
2976 UnaryOperator operator,
2977 Node expression,
2978 A arg) {
2979 return bulkHandleUnary(node, arg); 1898 return bulkHandleUnary(node, arg);
2980 } 1899 }
2981 1900
2982 @override 1901 @override
2983 R visitUnresolvedSuperUnary( 1902 R visitUnresolvedSuperUnary(
2984 Send node, 1903 Send node, UnaryOperator operator, FunctionElement function, A arg) {
2985 UnaryOperator operator,
2986 FunctionElement function,
2987 A arg) {
2988 return bulkHandleUnary(node, arg); 1904 return bulkHandleUnary(node, arg);
2989 } 1905 }
2990 } 1906 }
2991 1907
2992 /// Mixin that implements all purely structural visitor methods in 1908 /// Mixin that implements all purely structural visitor methods in
2993 /// [SemanticSendVisitor] by delegating to a bulk handler. 1909 /// [SemanticSendVisitor] by delegating to a bulk handler.
2994 /// 1910 ///
2995 /// Use this mixin to provide a trivial implementation for all purely structural 1911 /// Use this mixin to provide a trivial implementation for all purely structural
2996 /// visitor methods. 1912 /// visitor methods.
2997 abstract class BaseBulkMixin<R, A> 1913 abstract class BaseBulkMixin<R, A>
2998 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 1914 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
2999
3000 @override 1915 @override
3001 R visitAs( 1916 R visitAs(Send node, Node expression, DartType type, A arg) {
3002 Send node,
3003 Node expression,
3004 DartType type,
3005 A arg) {
3006 return bulkHandleNode(node, 'As cast `#` unhandled.', arg); 1917 return bulkHandleNode(node, 'As cast `#` unhandled.', arg);
3007 } 1918 }
3008 1919
3009 @override 1920 @override
3010 R visitIs( 1921 R visitIs(Send node, Node expression, DartType type, A arg) {
3011 Send node,
3012 Node expression,
3013 DartType type,
3014 A arg) {
3015 return bulkHandleNode(node, 'Is test `#` unhandled.', arg); 1922 return bulkHandleNode(node, 'Is test `#` unhandled.', arg);
3016 } 1923 }
3017 1924
3018 @override 1925 @override
3019 R visitIsNot( 1926 R visitIsNot(Send node, Node expression, DartType type, A arg) {
3020 Send node,
3021 Node expression,
3022 DartType type,
3023 A arg) {
3024 return bulkHandleNode(node, 'Is not test `#` unhandled.', arg); 1927 return bulkHandleNode(node, 'Is not test `#` unhandled.', arg);
3025 } 1928 }
3026 1929
3027 @override 1930 @override
3028 R visitIfNull( 1931 R visitIfNull(Send node, Node left, Node right, A arg) {
3029 Send node,
3030 Node left,
3031 Node right,
3032 A arg) {
3033 return bulkHandleNode(node, 'If-null (Lazy ?? `#`) unhandled.', arg); 1932 return bulkHandleNode(node, 'If-null (Lazy ?? `#`) unhandled.', arg);
3034 } 1933 }
3035 1934
3036 @override 1935 @override
3037 R visitLogicalAnd( 1936 R visitLogicalAnd(Send node, Node left, Node right, A arg) {
3038 Send node,
3039 Node left,
3040 Node right,
3041 A arg) {
3042 return bulkHandleNode(node, 'Lazy and `#` unhandled.', arg); 1937 return bulkHandleNode(node, 'Lazy and `#` unhandled.', arg);
3043 } 1938 }
3044 1939
3045 @override 1940 @override
3046 R visitLogicalOr( 1941 R visitLogicalOr(Send node, Node left, Node right, A arg) {
3047 Send node,
3048 Node left,
3049 Node right,
3050 A arg) {
3051 return bulkHandleNode(node, 'Lazy or `#` unhandled.', arg); 1942 return bulkHandleNode(node, 'Lazy or `#` unhandled.', arg);
3052 } 1943 }
3053 1944
3054 @override 1945 @override
3055 void previsitDeferredAccess( 1946 void previsitDeferredAccess(Send node, PrefixElement prefix, A arg) {
3056 Send node,
3057 PrefixElement prefix,
3058 A arg) {
3059 bulkHandleNode(node, 'Deferred access `#` unhandled.', arg); 1947 bulkHandleNode(node, 'Deferred access `#` unhandled.', arg);
3060 } 1948 }
3061 } 1949 }
3062 1950
3063 /// Mixin that implements all visitor methods for `super` calls in 1951 /// Mixin that implements all visitor methods for `super` calls in
3064 /// [SemanticSendVisitor] by delegating to a bulk handler. 1952 /// [SemanticSendVisitor] by delegating to a bulk handler.
3065 /// 1953 ///
3066 /// Use this mixin to provide a trivial implementation for `super` calls 1954 /// Use this mixin to provide a trivial implementation for `super` calls
3067 /// visitor methods. 1955 /// visitor methods.
3068 abstract class SuperBulkMixin<R, A> 1956 abstract class SuperBulkMixin<R, A>
3069 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 1957 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
3070
3071 R bulkHandleSuper(Send node, A arg) { 1958 R bulkHandleSuper(Send node, A arg) {
3072 return bulkHandleNode(node, "Super call `#` unhandled.", arg); 1959 return bulkHandleNode(node, "Super call `#` unhandled.", arg);
3073 } 1960 }
3074 1961
3075 @override 1962 @override
3076 R visitSuperBinary( 1963 R visitSuperBinary(Send node, FunctionElement function,
3077 Send node, 1964 BinaryOperator operator, Node argument, A arg) {
3078 FunctionElement function,
3079 BinaryOperator operator,
3080 Node argument,
3081 A arg) {
3082 return bulkHandleSuper(node, arg); 1965 return bulkHandleSuper(node, arg);
3083 } 1966 }
3084 1967
3085 @override 1968 @override
3086 R visitSuperCompoundIndexSet( 1969 R visitSuperCompoundIndexSet(
3087 SendSet node, 1970 SendSet node,
3088 FunctionElement getter, 1971 FunctionElement getter,
3089 FunctionElement setter, 1972 FunctionElement setter,
3090 Node index, 1973 Node index,
3091 AssignmentOperator operator, 1974 AssignmentOperator operator,
3092 Node rhs, 1975 Node rhs,
3093 A arg) { 1976 A arg) {
3094 return bulkHandleSuper(node, arg); 1977 return bulkHandleSuper(node, arg);
3095 } 1978 }
3096 1979
3097 @override 1980 @override
3098 R visitSuperEquals( 1981 R visitSuperEquals(
3099 Send node, 1982 Send node, FunctionElement function, Node argument, A arg) {
3100 FunctionElement function, 1983 return bulkHandleSuper(node, arg);
3101 Node argument, 1984 }
3102 A arg) { 1985
3103 return bulkHandleSuper(node, arg); 1986 @override
3104 } 1987 R visitSuperFieldCompound(Send node, FieldElement field,
3105 1988 AssignmentOperator operator, Node rhs, A arg) {
3106 @override 1989 return bulkHandleSuper(node, arg);
3107 R visitSuperFieldCompound( 1990 }
3108 Send node, 1991
3109 FieldElement field, 1992 @override
3110 AssignmentOperator operator, 1993 R visitSuperFieldFieldPostfix(Send node, FieldElement readField,
3111 Node rhs, 1994 FieldElement writtenField, IncDecOperator operator, A arg) {
3112 A arg) { 1995 return bulkHandleSuper(node, arg);
3113 return bulkHandleSuper(node, arg); 1996 }
3114 } 1997
3115 1998 @override
3116 @override 1999 R visitSuperFieldFieldPrefix(Send node, FieldElement readField,
3117 R visitSuperFieldFieldPostfix( 2000 FieldElement writtenField, IncDecOperator operator, A arg) {
3118 Send node, 2001 return bulkHandleSuper(node, arg);
3119 FieldElement readField, 2002 }
3120 FieldElement writtenField, 2003
3121 IncDecOperator operator, 2004 @override
3122 A arg) { 2005 R visitSuperFieldGet(Send node, FieldElement field, A arg) {
3123 return bulkHandleSuper(node, arg); 2006 return bulkHandleSuper(node, arg);
3124 } 2007 }
3125 2008
3126 @override 2009 @override
3127 R visitSuperFieldFieldPrefix( 2010 R visitSuperFieldInvoke(Send node, FieldElement field, NodeList arguments,
3128 Send node, 2011 CallStructure callStructure, A arg) {
3129 FieldElement readField,
3130 FieldElement writtenField,
3131 IncDecOperator operator,
3132 A arg) {
3133 return bulkHandleSuper(node, arg);
3134 }
3135
3136 @override
3137 R visitSuperFieldGet(
3138 Send node,
3139 FieldElement field,
3140 A arg) {
3141 return bulkHandleSuper(node, arg);
3142 }
3143
3144 @override
3145 R visitSuperFieldInvoke(
3146 Send node,
3147 FieldElement field,
3148 NodeList arguments,
3149 CallStructure callStructure,
3150 A arg) {
3151 return bulkHandleSuper(node, arg); 2012 return bulkHandleSuper(node, arg);
3152 } 2013 }
3153 2014
3154 @override 2015 @override
3155 R visitSuperFieldPostfix( 2016 R visitSuperFieldPostfix(
3156 Send node, 2017 Send node, FieldElement field, IncDecOperator operator, A arg) {
3157 FieldElement field,
3158 IncDecOperator operator,
3159 A arg) {
3160 return bulkHandleSuper(node, arg); 2018 return bulkHandleSuper(node, arg);
3161 } 2019 }
3162 2020
3163 @override 2021 @override
3164 R visitSuperFieldPrefix( 2022 R visitSuperFieldPrefix(
3165 Send node, 2023 Send node, FieldElement field, IncDecOperator operator, A arg) {
3166 FieldElement field, 2024 return bulkHandleSuper(node, arg);
3167 IncDecOperator operator, 2025 }
3168 A arg) { 2026
3169 return bulkHandleSuper(node, arg); 2027 @override
3170 } 2028 R visitSuperFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
3171 2029 return bulkHandleSuper(node, arg);
3172 @override 2030 }
3173 R visitSuperFieldSet( 2031
3174 SendSet node, 2032 @override
3175 FieldElement field, 2033 R visitSuperFieldSetterCompound(Send node, FieldElement field,
3176 Node rhs, 2034 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
3177 A arg) { 2035 return bulkHandleSuper(node, arg);
3178 return bulkHandleSuper(node, arg); 2036 }
3179 } 2037
3180 2038 @override
3181 @override 2039 R visitSuperFieldSetterPostfix(Send node, FieldElement field,
3182 R visitSuperFieldSetterCompound( 2040 FunctionElement setter, IncDecOperator operator, A arg) {
3183 Send node, 2041 return bulkHandleSuper(node, arg);
3184 FieldElement field, 2042 }
3185 FunctionElement setter, 2043
3186 AssignmentOperator operator, 2044 @override
3187 Node rhs, 2045 R visitSuperFieldSetterPrefix(Send node, FieldElement field,
3188 A arg) { 2046 FunctionElement setter, IncDecOperator operator, A arg) {
3189 return bulkHandleSuper(node, arg); 2047 return bulkHandleSuper(node, arg);
3190 } 2048 }
3191 2049
3192 @override 2050 @override
3193 R visitSuperFieldSetterPostfix( 2051 R visitSuperGetterFieldCompound(Send node, FunctionElement getter,
3194 Send node, 2052 FieldElement field, AssignmentOperator operator, Node rhs, A arg) {
3195 FieldElement field, 2053 return bulkHandleSuper(node, arg);
3196 FunctionElement setter, 2054 }
3197 IncDecOperator operator, 2055
3198 A arg) { 2056 @override
3199 return bulkHandleSuper(node, arg); 2057 R visitSuperGetterFieldPostfix(Send node, FunctionElement getter,
3200 } 2058 FieldElement field, IncDecOperator operator, A arg) {
3201 2059 return bulkHandleSuper(node, arg);
3202 @override 2060 }
3203 R visitSuperFieldSetterPrefix( 2061
3204 Send node, 2062 @override
3205 FieldElement field, 2063 R visitSuperGetterFieldPrefix(Send node, FunctionElement getter,
3206 FunctionElement setter, 2064 FieldElement field, IncDecOperator operator, A arg) {
3207 IncDecOperator operator, 2065 return bulkHandleSuper(node, arg);
3208 A arg) { 2066 }
3209 return bulkHandleSuper(node, arg); 2067
3210 } 2068 @override
3211 2069 R visitSuperGetterGet(Send node, FunctionElement getter, A arg) {
3212 @override 2070 return bulkHandleSuper(node, arg);
3213 R visitSuperGetterFieldCompound( 2071 }
3214 Send node, 2072
3215 FunctionElement getter, 2073 @override
3216 FieldElement field, 2074 R visitSuperGetterInvoke(Send node, FunctionElement getter,
3217 AssignmentOperator operator, 2075 NodeList arguments, CallStructure callStructure, A arg) {
3218 Node rhs, 2076 return bulkHandleSuper(node, arg);
3219 A arg) { 2077 }
3220 return bulkHandleSuper(node, arg); 2078
3221 } 2079 @override
3222 2080 R visitSuperGetterSetterCompound(Send node, FunctionElement getter,
3223 @override 2081 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
3224 R visitSuperGetterFieldPostfix( 2082 return bulkHandleSuper(node, arg);
3225 Send node, 2083 }
3226 FunctionElement getter, 2084
3227 FieldElement field, 2085 @override
3228 IncDecOperator operator, 2086 R visitSuperGetterSetterPostfix(Send node, FunctionElement getter,
3229 A arg) { 2087 FunctionElement setter, IncDecOperator operator, A arg) {
3230 return bulkHandleSuper(node, arg); 2088 return bulkHandleSuper(node, arg);
3231 } 2089 }
3232 2090
3233 @override 2091 @override
3234 R visitSuperGetterFieldPrefix( 2092 R visitSuperGetterSetterPrefix(Send node, FunctionElement getter,
3235 Send node, 2093 FunctionElement setter, IncDecOperator operator, A arg) {
3236 FunctionElement getter,
3237 FieldElement field,
3238 IncDecOperator operator,
3239 A arg) {
3240 return bulkHandleSuper(node, arg);
3241 }
3242
3243 @override
3244 R visitSuperGetterGet(
3245 Send node,
3246 FunctionElement getter,
3247 A arg) {
3248 return bulkHandleSuper(node, arg);
3249 }
3250
3251 @override
3252 R visitSuperGetterInvoke(
3253 Send node,
3254 FunctionElement getter,
3255 NodeList arguments,
3256 CallStructure callStructure,
3257 A arg) {
3258 return bulkHandleSuper(node, arg);
3259 }
3260
3261 @override
3262 R visitSuperGetterSetterCompound(
3263 Send node,
3264 FunctionElement getter,
3265 FunctionElement setter,
3266 AssignmentOperator operator,
3267 Node rhs,
3268 A arg) {
3269 return bulkHandleSuper(node, arg);
3270 }
3271
3272 @override
3273 R visitSuperGetterSetterPostfix(
3274 Send node,
3275 FunctionElement getter,
3276 FunctionElement setter,
3277 IncDecOperator operator,
3278 A arg) {
3279 return bulkHandleSuper(node, arg);
3280 }
3281
3282 @override
3283 R visitSuperGetterSetterPrefix(
3284 Send node,
3285 FunctionElement getter,
3286 FunctionElement setter,
3287 IncDecOperator operator,
3288 A arg) {
3289 return bulkHandleSuper(node, arg); 2094 return bulkHandleSuper(node, arg);
3290 } 2095 }
3291 2096
3292 @override 2097 @override
3293 R visitSuperIndexSet( 2098 R visitSuperIndexSet(
3294 SendSet node, 2099 SendSet node, FunctionElement function, Node index, Node rhs, A arg) {
3295 FunctionElement function, 2100 return bulkHandleSuper(node, arg);
3296 Node index, 2101 }
3297 Node rhs, 2102
3298 A arg) { 2103 @override
3299 return bulkHandleSuper(node, arg); 2104 R visitSuperMethodGet(Send node, MethodElement method, A arg) {
3300 } 2105 return bulkHandleSuper(node, arg);
3301 2106 }
3302 @override 2107
3303 R visitSuperMethodGet( 2108 @override
3304 Send node, 2109 R visitSuperMethodInvoke(Send node, MethodElement method, NodeList arguments,
3305 MethodElement method, 2110 CallStructure callStructure, A arg) {
3306 A arg) { 2111 return bulkHandleSuper(node, arg);
3307 return bulkHandleSuper(node, arg); 2112 }
3308 } 2113
3309 2114 @override
3310 @override 2115 R visitSuperMethodIncompatibleInvoke(Send node, MethodElement method,
3311 R visitSuperMethodInvoke( 2116 NodeList arguments, CallStructure callStructure, A arg) {
3312 Send node, 2117 return bulkHandleSuper(node, arg);
3313 MethodElement method, 2118 }
3314 NodeList arguments, 2119
3315 CallStructure callStructure, 2120 @override
3316 A arg) { 2121 R visitSuperMethodSetterCompound(Send node, FunctionElement method,
3317 return bulkHandleSuper(node, arg); 2122 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
3318 } 2123 return bulkHandleSuper(node, arg);
3319 2124 }
3320 @override 2125
3321 R visitSuperMethodIncompatibleInvoke( 2126 @override
3322 Send node, 2127 R visitSuperMethodSetterPostfix(Send node, FunctionElement method,
3323 MethodElement method, 2128 FunctionElement setter, IncDecOperator operator, A arg) {
3324 NodeList arguments, 2129 return bulkHandleSuper(node, arg);
3325 CallStructure callStructure, 2130 }
3326 A arg) { 2131
3327 return bulkHandleSuper(node, arg); 2132 @override
3328 } 2133 R visitSuperMethodSetterPrefix(Send node, FunctionElement method,
3329 2134 FunctionElement setter, IncDecOperator operator, A arg) {
3330 @override
3331 R visitSuperMethodSetterCompound(
3332 Send node,
3333 FunctionElement method,
3334 FunctionElement setter,
3335 AssignmentOperator operator,
3336 Node rhs,
3337 A arg) {
3338 return bulkHandleSuper(node, arg);
3339 }
3340
3341 @override
3342 R visitSuperMethodSetterPostfix(
3343 Send node,
3344 FunctionElement method,
3345 FunctionElement setter,
3346 IncDecOperator operator,
3347 A arg) {
3348 return bulkHandleSuper(node, arg);
3349 }
3350
3351 @override
3352 R visitSuperMethodSetterPrefix(
3353 Send node,
3354 FunctionElement method,
3355 FunctionElement setter,
3356 IncDecOperator operator,
3357 A arg) {
3358 return bulkHandleSuper(node, arg); 2135 return bulkHandleSuper(node, arg);
3359 } 2136 }
3360 2137
3361 @override 2138 @override
3362 R visitSuperNotEquals( 2139 R visitSuperNotEquals(
3363 Send node, 2140 Send node, FunctionElement function, Node argument, A arg) {
3364 FunctionElement function, 2141 return bulkHandleSuper(node, arg);
3365 Node argument, 2142 }
3366 A arg) { 2143
3367 return bulkHandleSuper(node, arg); 2144 @override
3368 } 2145 R visitSuperSetterSet(SendSet node, FunctionElement setter, Node rhs, A arg) {
3369
3370 @override
3371 R visitSuperSetterSet(
3372 SendSet node,
3373 FunctionElement setter,
3374 Node rhs,
3375 A arg) {
3376 return bulkHandleSuper(node, arg); 2146 return bulkHandleSuper(node, arg);
3377 } 2147 }
3378 2148
3379 @override 2149 @override
3380 R visitSuperUnary( 2150 R visitSuperUnary(
3381 Send node, 2151 Send node, UnaryOperator operator, FunctionElement function, A arg) {
3382 UnaryOperator operator, 2152 return bulkHandleSuper(node, arg);
3383 FunctionElement function, 2153 }
3384 A arg) { 2154
3385 return bulkHandleSuper(node, arg); 2155 @override
3386 } 2156 R visitUnresolvedSuperBinary(Send node, Element element,
3387 2157 BinaryOperator operator, Node argument, A arg) {
3388 @override 2158 return bulkHandleSuper(node, arg);
3389 R visitUnresolvedSuperBinary( 2159 }
3390 Send node, 2160
3391 Element element, 2161 @override
3392 BinaryOperator operator, 2162 R visitUnresolvedSuperGet(Send node, Element element, A arg) {
3393 Node argument, 2163 return bulkHandleSuper(node, arg);
3394 A arg) { 2164 }
3395 return bulkHandleSuper(node, arg); 2165
3396 } 2166 @override
3397 2167 R visitUnresolvedSuperSet(Send node, Element element, Node rhs, A arg) {
3398 @override 2168 return bulkHandleSuper(node, arg);
3399 R visitUnresolvedSuperGet( 2169 }
3400 Send node, 2170
3401 Element element, 2171 @override
3402 A arg) { 2172 R visitUnresolvedSuperInvoke(Send node, Element function, NodeList arguments,
3403 return bulkHandleSuper(node, arg); 2173 Selector selector, A arg) {
3404 } 2174 return bulkHandleSuper(node, arg);
3405 2175 }
3406 @override 2176
3407 R visitUnresolvedSuperSet( 2177 @override
3408 Send node, 2178 R visitUnresolvedSuperIndex(Send node, Element function, Node index, A arg) {
3409 Element element,
3410 Node rhs,
3411 A arg) {
3412 return bulkHandleSuper(node, arg);
3413 }
3414
3415 @override
3416 R visitUnresolvedSuperInvoke(
3417 Send node,
3418 Element function,
3419 NodeList arguments,
3420 Selector selector,
3421 A arg) {
3422 return bulkHandleSuper(node, arg);
3423 }
3424
3425 @override
3426 R visitUnresolvedSuperIndex(
3427 Send node,
3428 Element function,
3429 Node index,
3430 A arg) {
3431 return bulkHandleSuper(node, arg); 2179 return bulkHandleSuper(node, arg);
3432 } 2180 }
3433 2181
3434 @override 2182 @override
3435 R visitUnresolvedSuperUnary( 2183 R visitUnresolvedSuperUnary(
3436 Send node, 2184 Send node, UnaryOperator operator, Element element, A arg) {
3437 UnaryOperator operator,
3438 Element element,
3439 A arg) {
3440 return bulkHandleSuper(node, arg); 2185 return bulkHandleSuper(node, arg);
3441 } 2186 }
3442 } 2187 }
3443 2188
3444 abstract class NewBulkMixin<R, A> 2189 abstract class NewBulkMixin<R, A>
3445 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> { 2190 implements SemanticSendVisitor<R, A>, BulkHandle<R, A> {
3446
3447 R bulkHandleNew(NewExpression node, A arg) { 2191 R bulkHandleNew(NewExpression node, A arg) {
3448 return bulkHandleNode( 2192 return bulkHandleNode(node, "Constructor invocation `#` unhandled.", arg);
3449 node, "Constructor invocation `#` unhandled.", arg); 2193 }
3450 } 2194
3451 2195 @override
3452 @override
3453 R visitAbstractClassConstructorInvoke( 2196 R visitAbstractClassConstructorInvoke(
3454 NewExpression node, 2197 NewExpression node,
3455 ConstructorElement element, 2198 ConstructorElement element,
3456 InterfaceType type, 2199 InterfaceType type,
3457 NodeList arguments, 2200 NodeList arguments,
3458 CallStructure callStructure, 2201 CallStructure callStructure,
3459 A arg) { 2202 A arg) {
3460 return bulkHandleNew(node, arg); 2203 return bulkHandleNew(node, arg);
3461 } 2204 }
3462 2205
3463 @override 2206 @override
3464 R visitConstConstructorInvoke( 2207 R visitConstConstructorInvoke(
3465 NewExpression node, 2208 NewExpression node, ConstructedConstantExpression constant, A arg) {
3466 ConstructedConstantExpression constant,
3467 A arg) {
3468 return bulkHandleNew(node, arg); 2209 return bulkHandleNew(node, arg);
3469 } 2210 }
3470 2211
3471 @override 2212 @override
3472 R visitBoolFromEnvironmentConstructorInvoke( 2213 R visitBoolFromEnvironmentConstructorInvoke(NewExpression node,
3473 NewExpression node, 2214 BoolFromEnvironmentConstantExpression constant, A arg) {
3474 BoolFromEnvironmentConstantExpression constant,
3475 A arg) {
3476 return bulkHandleNew(node, arg); 2215 return bulkHandleNew(node, arg);
3477 } 2216 }
3478 2217
3479 @override 2218 @override
3480 R visitIntFromEnvironmentConstructorInvoke( 2219 R visitIntFromEnvironmentConstructorInvoke(NewExpression node,
3481 NewExpression node, 2220 IntFromEnvironmentConstantExpression constant, A arg) {
3482 IntFromEnvironmentConstantExpression constant,
3483 A arg) {
3484 return bulkHandleNew(node, arg); 2221 return bulkHandleNew(node, arg);
3485 } 2222 }
3486 2223
3487 @override 2224 @override
3488 R visitStringFromEnvironmentConstructorInvoke( 2225 R visitStringFromEnvironmentConstructorInvoke(NewExpression node,
3489 NewExpression node, 2226 StringFromEnvironmentConstantExpression constant, A arg) {
3490 StringFromEnvironmentConstantExpression constant,
3491 A arg) {
3492 return bulkHandleNew(node, arg); 2227 return bulkHandleNew(node, arg);
3493 } 2228 }
3494 2229
3495 @override 2230 @override
3496 R visitConstructorIncompatibleInvoke( 2231 R visitConstructorIncompatibleInvoke(
3497 NewExpression node, 2232 NewExpression node,
3498 ConstructorElement constructor, 2233 ConstructorElement constructor,
3499 InterfaceType type, 2234 InterfaceType type,
3500 NodeList arguments, 2235 NodeList arguments,
3501 CallStructure callStructure, 2236 CallStructure callStructure,
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
3543 InterfaceType type, 2278 InterfaceType type,
3544 ConstructorElement effectiveTarget, 2279 ConstructorElement effectiveTarget,
3545 InterfaceType effectiveTargetType, 2280 InterfaceType effectiveTargetType,
3546 NodeList arguments, 2281 NodeList arguments,
3547 CallStructure callStructure, 2282 CallStructure callStructure,
3548 A arg) { 2283 A arg) {
3549 return bulkHandleNew(node, arg); 2284 return bulkHandleNew(node, arg);
3550 } 2285 }
3551 2286
3552 @override 2287 @override
3553 R visitUnresolvedClassConstructorInvoke( 2288 R visitUnresolvedClassConstructorInvoke(NewExpression node, Element element,
3554 NewExpression node, 2289 DartType type, NodeList arguments, Selector selector, A arg) {
3555 Element element,
3556 DartType type,
3557 NodeList arguments,
3558 Selector selector,
3559 A arg) {
3560 return bulkHandleNew(node, arg); 2290 return bulkHandleNew(node, arg);
3561 } 2291 }
3562 2292
3563 @override 2293 @override
3564 R visitUnresolvedConstructorInvoke( 2294 R visitUnresolvedConstructorInvoke(NewExpression node, Element constructor,
3565 NewExpression node, 2295 DartType type, NodeList arguments, Selector selector, A arg) {
3566 Element constructor,
3567 DartType type,
3568 NodeList arguments,
3569 Selector selector,
3570 A arg) {
3571 return bulkHandleNew(node, arg); 2296 return bulkHandleNew(node, arg);
3572 } 2297 }
3573 2298
3574 @override 2299 @override
3575 R visitUnresolvedRedirectingFactoryConstructorInvoke( 2300 R visitUnresolvedRedirectingFactoryConstructorInvoke(
3576 NewExpression node, 2301 NewExpression node,
3577 ConstructorElement constructor, 2302 ConstructorElement constructor,
3578 InterfaceType type, 2303 InterfaceType type,
3579 NodeList arguments, 2304 NodeList arguments,
3580 CallStructure callStructure, 2305 CallStructure callStructure,
3581 A arg) { 2306 A arg) {
3582 return bulkHandleNew(node, arg); 2307 return bulkHandleNew(node, arg);
3583 } 2308 }
3584 } 2309 }
3585 2310
3586 /// Visitor that implements [SemanticSendVisitor] by the use of `BulkX` mixins. 2311 /// Visitor that implements [SemanticSendVisitor] by the use of `BulkX` mixins.
3587 /// 2312 ///
3588 /// This class is useful in itself, but shows how to use the `BulkX` mixins and 2313 /// This class is useful in itself, but shows how to use the `BulkX` mixins and
3589 /// tests that the union of the `BulkX` mixins implement all `visit` and `error` 2314 /// tests that the union of the `BulkX` mixins implement all `visit` and `error`
3590 /// methods of [SemanticSendVisitor]. 2315 /// methods of [SemanticSendVisitor].
3591 class BulkSendVisitor<R, A> extends SemanticSendVisitor<R, A> 2316 class BulkSendVisitor<R, A> extends SemanticSendVisitor<R, A>
3592 with GetBulkMixin<R, A>, 2317 with
3593 SetBulkMixin<R, A>, 2318 GetBulkMixin<R, A>,
3594 ErrorBulkMixin<R, A>, 2319 SetBulkMixin<R, A>,
3595 InvokeBulkMixin<R, A>, 2320 ErrorBulkMixin<R, A>,
3596 IndexSetBulkMixin<R, A>, 2321 InvokeBulkMixin<R, A>,
3597 CompoundBulkMixin<R, A>, 2322 IndexSetBulkMixin<R, A>,
3598 SetIfNullBulkMixin<R, A>, 2323 CompoundBulkMixin<R, A>,
3599 UnaryBulkMixin<R, A>, 2324 SetIfNullBulkMixin<R, A>,
3600 BaseBulkMixin<R, A>, 2325 UnaryBulkMixin<R, A>,
3601 BinaryBulkMixin<R, A>, 2326 BaseBulkMixin<R, A>,
3602 PrefixBulkMixin<R, A>, 2327 BinaryBulkMixin<R, A>,
3603 PostfixBulkMixin<R, A>, 2328 PrefixBulkMixin<R, A>,
3604 NewBulkMixin<R, A> { 2329 PostfixBulkMixin<R, A>,
2330 NewBulkMixin<R, A> {
3605 @override 2331 @override
3606 R apply(Node node, A arg) { 2332 R apply(Node node, A arg) {
3607 throw new UnimplementedError("BulkSendVisitor.apply unimplemented"); 2333 throw new UnimplementedError("BulkSendVisitor.apply unimplemented");
3608 } 2334 }
3609 2335
3610 @override 2336 @override
3611 R bulkHandleNode(Node node, String message, A arg) { 2337 R bulkHandleNode(Node node, String message, A arg) {
3612 throw new UnimplementedError( 2338 throw new UnimplementedError(
3613 "BulkSendVisitor.bulkHandleNode unimplemented"); 2339 "BulkSendVisitor.bulkHandleNode unimplemented");
3614 } 2340 }
3615 } 2341 }
3616 2342
3617 /// Mixin that implements all `visitXParameterDecl` and 2343 /// Mixin that implements all `visitXParameterDecl` and
3618 /// `visitXInitializingFormalDecl` methods of [SemanticDeclarationVisitor] 2344 /// `visitXInitializingFormalDecl` methods of [SemanticDeclarationVisitor]
3619 /// by delegating to a bulk handler. 2345 /// by delegating to a bulk handler.
3620 /// 2346 ///
3621 /// Use this mixin to provide a trivial implementation for these methods. 2347 /// Use this mixin to provide a trivial implementation for these methods.
3622 abstract class ParameterBulkMixin<R, A> 2348 abstract class ParameterBulkMixin<R, A>
3623 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> { 2349 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> {
3624
3625 R bulkHandleParameterDeclaration(VariableDefinitions node, A arg) { 2350 R bulkHandleParameterDeclaration(VariableDefinitions node, A arg) {
3626 return bulkHandleNode( 2351 return bulkHandleNode(node, "Parameter declaration `#` unhandled.", arg);
3627 node, "Parameter declaration `#` unhandled.", arg);
3628 } 2352 }
3629 2353
3630 @override 2354 @override
3631 R visitInitializingFormalDeclaration( 2355 R visitInitializingFormalDeclaration(VariableDefinitions node,
3632 VariableDefinitions node, 2356 Node definition, InitializingFormalElement parameter, int index, A arg) {
3633 Node definition,
3634 InitializingFormalElement parameter,
3635 int index,
3636 A arg) {
3637 return bulkHandleParameterDeclaration(node, arg); 2357 return bulkHandleParameterDeclaration(node, arg);
3638 } 2358 }
3639 2359
3640 @override 2360 @override
3641 R visitNamedInitializingFormalDeclaration( 2361 R visitNamedInitializingFormalDeclaration(
3642 VariableDefinitions node, 2362 VariableDefinitions node,
3643 Node definition, 2363 Node definition,
3644 InitializingFormalElement parameter, 2364 InitializingFormalElement parameter,
3645 ConstantExpression defaultValue, 2365 ConstantExpression defaultValue,
3646 A arg) { 2366 A arg) {
3647 return bulkHandleParameterDeclaration(node, arg); 2367 return bulkHandleParameterDeclaration(node, arg);
3648 } 2368 }
3649 2369
3650 @override 2370 @override
3651 R visitNamedParameterDeclaration( 2371 R visitNamedParameterDeclaration(VariableDefinitions node, Node definition,
3652 VariableDefinitions node, 2372 ParameterElement parameter, ConstantExpression defaultValue, A arg) {
3653 Node definition,
3654 ParameterElement parameter,
3655 ConstantExpression defaultValue,
3656 A arg) {
3657 return bulkHandleParameterDeclaration(node, arg); 2373 return bulkHandleParameterDeclaration(node, arg);
3658 } 2374 }
3659 2375
3660 @override 2376 @override
3661 R visitOptionalInitializingFormalDeclaration( 2377 R visitOptionalInitializingFormalDeclaration(
3662 VariableDefinitions node, 2378 VariableDefinitions node,
3663 Node definition, 2379 Node definition,
3664 InitializingFormalElement parameter, 2380 InitializingFormalElement parameter,
3665 ConstantExpression defaultValue, 2381 ConstantExpression defaultValue,
3666 int index, 2382 int index,
3667 A arg) { 2383 A arg) {
3668 return bulkHandleParameterDeclaration(node, arg); 2384 return bulkHandleParameterDeclaration(node, arg);
3669 } 2385 }
3670 2386
3671 @override 2387 @override
3672 R visitOptionalParameterDeclaration( 2388 R visitOptionalParameterDeclaration(
3673 VariableDefinitions node, 2389 VariableDefinitions node,
3674 Node definition, 2390 Node definition,
3675 ParameterElement parameter, 2391 ParameterElement parameter,
3676 ConstantExpression defaultValue, 2392 ConstantExpression defaultValue,
3677 int index, 2393 int index,
3678 A arg) { 2394 A arg) {
3679 return bulkHandleParameterDeclaration(node, arg); 2395 return bulkHandleParameterDeclaration(node, arg);
3680 } 2396 }
3681 2397
3682 @override 2398 @override
3683 R visitParameterDeclaration( 2399 R visitParameterDeclaration(VariableDefinitions node, Node definition,
3684 VariableDefinitions node, 2400 ParameterElement parameter, int index, A arg) {
3685 Node definition,
3686 ParameterElement parameter,
3687 int index,
3688 A arg) {
3689 return bulkHandleParameterDeclaration(node, arg); 2401 return bulkHandleParameterDeclaration(node, arg);
3690 } 2402 }
3691 } 2403 }
3692 2404
3693 /// Mixin that implements all `visitXConstructorDecl` methods of 2405 /// Mixin that implements all `visitXConstructorDecl` methods of
3694 /// [SemanticDeclarationVisitor] by delegating to a bulk handler. 2406 /// [SemanticDeclarationVisitor] by delegating to a bulk handler.
3695 /// 2407 ///
3696 /// Use this mixin to provide a trivial implementation for these methods. 2408 /// Use this mixin to provide a trivial implementation for these methods.
3697 abstract class ConstructorBulkMixin<R, A> 2409 abstract class ConstructorBulkMixin<R, A>
3698 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> { 2410 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> {
3699
3700 R bulkHandleConstructorDeclaration(FunctionExpression node, A arg) { 2411 R bulkHandleConstructorDeclaration(FunctionExpression node, A arg) {
3701 return bulkHandleNode( 2412 return bulkHandleNode(node, "Constructor declaration `#` unhandled.", arg);
3702 node, "Constructor declaration `#` unhandled.", arg);
3703 } 2413 }
3704 2414
3705 @override 2415 @override
3706 R visitFactoryConstructorDeclaration( 2416 R visitFactoryConstructorDeclaration(FunctionExpression node,
3707 FunctionExpression node, 2417 ConstructorElement constructor, NodeList parameters, Node body, A arg) {
3708 ConstructorElement constructor,
3709 NodeList parameters,
3710 Node body,
3711 A arg) {
3712 return bulkHandleConstructorDeclaration(node, arg); 2418 return bulkHandleConstructorDeclaration(node, arg);
3713 } 2419 }
3714 2420
3715 @override 2421 @override
3716 R visitGenerativeConstructorDeclaration( 2422 R visitGenerativeConstructorDeclaration(
3717 FunctionExpression node, 2423 FunctionExpression node,
3718 ConstructorElement constructor, 2424 ConstructorElement constructor,
3719 NodeList parameters, 2425 NodeList parameters,
3720 NodeList initializers, 2426 NodeList initializers,
3721 Node body, 2427 Node body,
(...skipping 22 matching lines...) Expand all
3744 return bulkHandleConstructorDeclaration(node, arg); 2450 return bulkHandleConstructorDeclaration(node, arg);
3745 } 2451 }
3746 } 2452 }
3747 2453
3748 /// Mixin that implements all constructor initializer visitor methods of 2454 /// Mixin that implements all constructor initializer visitor methods of
3749 /// [SemanticDeclarationVisitor] by delegating to a bulk handler. 2455 /// [SemanticDeclarationVisitor] by delegating to a bulk handler.
3750 /// 2456 ///
3751 /// Use this mixin to provide a trivial implementation for these methods. 2457 /// Use this mixin to provide a trivial implementation for these methods.
3752 abstract class InitializerBulkMixin<R, A> 2458 abstract class InitializerBulkMixin<R, A>
3753 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> { 2459 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> {
3754
3755 R bulkHandleInitializer(Node node, A arg) { 2460 R bulkHandleInitializer(Node node, A arg) {
3756 return bulkHandleNode( 2461 return bulkHandleNode(node, "Initializer `#` unhandled.", arg);
3757 node, "Initializer `#` unhandled.", arg);
3758 } 2462 }
3759 2463
3760 @override 2464 @override
3761 R errorUnresolvedFieldInitializer( 2465 R errorUnresolvedFieldInitializer(
3762 SendSet node, 2466 SendSet node, Element element, Node initializer, A arg) {
3763 Element element,
3764 Node initializer,
3765 A arg) {
3766 return bulkHandleInitializer(node, arg); 2467 return bulkHandleInitializer(node, arg);
3767 } 2468 }
3768 2469
3769 @override 2470 @override
3770 R errorUnresolvedSuperConstructorInvoke( 2471 R errorUnresolvedSuperConstructorInvoke(Send node, Element element,
3771 Send node, 2472 NodeList arguments, Selector selector, A arg) {
3772 Element element,
3773 NodeList arguments,
3774 Selector selector,
3775 A arg) {
3776 return bulkHandleInitializer(node, arg); 2473 return bulkHandleInitializer(node, arg);
3777 } 2474 }
3778 2475
3779 @override 2476 @override
3780 R errorUnresolvedThisConstructorInvoke( 2477 R errorUnresolvedThisConstructorInvoke(Send node, Element element,
3781 Send node, 2478 NodeList arguments, Selector selector, A arg) {
3782 Element element,
3783 NodeList arguments,
3784 Selector selector,
3785 A arg) {
3786 return bulkHandleInitializer(node, arg); 2479 return bulkHandleInitializer(node, arg);
3787 } 2480 }
3788 2481
3789 @override 2482 @override
3790 R visitFieldInitializer( 2483 R visitFieldInitializer(
3791 SendSet node, 2484 SendSet node, FieldElement field, Node initializer, A arg) {
3792 FieldElement field,
3793 Node initializer,
3794 A arg) {
3795 return bulkHandleInitializer(node, arg); 2485 return bulkHandleInitializer(node, arg);
3796 } 2486 }
3797 2487
3798 @override 2488 @override
3799 R visitSuperConstructorInvoke( 2489 R visitSuperConstructorInvoke(
3800 Send node, 2490 Send node,
3801 ConstructorElement superConstructor, 2491 ConstructorElement superConstructor,
3802 InterfaceType type, 2492 InterfaceType type,
3803 NodeList arguments, 2493 NodeList arguments,
3804 CallStructure callStructure, 2494 CallStructure callStructure,
3805 A arg) { 2495 A arg) {
3806 return bulkHandleInitializer(node, arg); 2496 return bulkHandleInitializer(node, arg);
3807 } 2497 }
3808 2498
3809 @override 2499 @override
3810 R visitImplicitSuperConstructorInvoke( 2500 R visitImplicitSuperConstructorInvoke(FunctionExpression node,
3811 FunctionExpression node, 2501 ConstructorElement superConstructor, InterfaceType type, A arg) {
3812 ConstructorElement superConstructor,
3813 InterfaceType type,
3814 A arg) {
3815 return bulkHandleInitializer(node, arg); 2502 return bulkHandleInitializer(node, arg);
3816 } 2503 }
3817 2504
3818 @override 2505 @override
3819 R visitThisConstructorInvoke( 2506 R visitThisConstructorInvoke(Send node, ConstructorElement thisConstructor,
3820 Send node, 2507 NodeList arguments, CallStructure callStructure, A arg) {
3821 ConstructorElement thisConstructor,
3822 NodeList arguments,
3823 CallStructure callStructure,
3824 A arg) {
3825 return bulkHandleInitializer(node, arg); 2508 return bulkHandleInitializer(node, arg);
3826 } 2509 }
3827 } 2510 }
3828 2511
3829 /// Mixin that implements all function declaration visitor methods of 2512 /// Mixin that implements all function declaration visitor methods of
3830 /// [SemanticDeclarationVisitor] by delegating to a bulk handler. 2513 /// [SemanticDeclarationVisitor] by delegating to a bulk handler.
3831 /// 2514 ///
3832 /// Use this mixin to provide a trivial implementation for these methods. 2515 /// Use this mixin to provide a trivial implementation for these methods.
3833 abstract class FunctionBulkMixin<R, A> 2516 abstract class FunctionBulkMixin<R, A>
3834 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> { 2517 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> {
3835
3836 R bulkHandleFunctionDeclaration(FunctionExpression node, A arg) { 2518 R bulkHandleFunctionDeclaration(FunctionExpression node, A arg) {
3837 return bulkHandleNode( 2519 return bulkHandleNode(node, "Function declaration `#` unhandled.", arg);
3838 node, "Function declaration `#` unhandled.", arg);
3839 } 2520 }
3840 2521
3841 @override 2522 @override
3842 R visitAbstractGetterDeclaration( 2523 R visitAbstractGetterDeclaration(
3843 FunctionExpression node, 2524 FunctionExpression node, MethodElement getter, A arg) {
3844 MethodElement getter,
3845 A arg) {
3846 return bulkHandleFunctionDeclaration(node, arg); 2525 return bulkHandleFunctionDeclaration(node, arg);
3847 } 2526 }
3848 2527
3849 @override 2528 @override
3850 R visitAbstractMethodDeclaration( 2529 R visitAbstractMethodDeclaration(FunctionExpression node,
3851 FunctionExpression node, 2530 MethodElement method, NodeList parameters, A arg) {
3852 MethodElement method,
3853 NodeList parameters,
3854 A arg) {
3855 return bulkHandleFunctionDeclaration(node, arg); 2531 return bulkHandleFunctionDeclaration(node, arg);
3856 } 2532 }
3857 2533
3858 @override 2534 @override
3859 R visitAbstractSetterDeclaration( 2535 R visitAbstractSetterDeclaration(FunctionExpression node,
3860 FunctionExpression node, 2536 MethodElement setter, NodeList parameters, A arg) {
3861 MethodElement setter,
3862 NodeList parameters,
3863 A arg) {
3864 return bulkHandleFunctionDeclaration(node, arg); 2537 return bulkHandleFunctionDeclaration(node, arg);
3865 } 2538 }
3866 2539
3867 @override 2540 @override
3868 R visitClosureDeclaration( 2541 R visitClosureDeclaration(FunctionExpression node,
3869 FunctionExpression node, 2542 LocalFunctionElement closure, NodeList parameters, Node body, A arg) {
3870 LocalFunctionElement closure,
3871 NodeList parameters,
3872 Node body,
3873 A arg) {
3874 return bulkHandleFunctionDeclaration(node, arg); 2543 return bulkHandleFunctionDeclaration(node, arg);
3875 } 2544 }
3876 2545
3877 @override 2546 @override
3878 R visitInstanceGetterDeclaration( 2547 R visitInstanceGetterDeclaration(
3879 FunctionExpression node, 2548 FunctionExpression node, MethodElement getter, Node body, A arg) {
3880 MethodElement getter,
3881 Node body,
3882 A arg) {
3883 return bulkHandleFunctionDeclaration(node, arg); 2549 return bulkHandleFunctionDeclaration(node, arg);
3884 } 2550 }
3885 2551
3886 @override 2552 @override
3887 R visitInstanceMethodDeclaration( 2553 R visitInstanceMethodDeclaration(FunctionExpression node,
3888 FunctionExpression node, 2554 MethodElement method, NodeList parameters, Node body, A arg) {
3889 MethodElement method,
3890 NodeList parameters,
3891 Node body,
3892 A arg) {
3893 return bulkHandleFunctionDeclaration(node, arg); 2555 return bulkHandleFunctionDeclaration(node, arg);
3894 } 2556 }
3895 2557
3896 @override 2558 @override
3897 R visitInstanceSetterDeclaration( 2559 R visitInstanceSetterDeclaration(FunctionExpression node,
3898 FunctionExpression node, 2560 MethodElement setter, NodeList parameters, Node body, A arg) {
3899 MethodElement setter,
3900 NodeList parameters,
3901 Node body,
3902 A arg) {
3903 return bulkHandleFunctionDeclaration(node, arg); 2561 return bulkHandleFunctionDeclaration(node, arg);
3904 } 2562 }
3905 2563
3906 @override 2564 @override
3907 R visitLocalFunctionDeclaration( 2565 R visitLocalFunctionDeclaration(FunctionExpression node,
3908 FunctionExpression node, 2566 LocalFunctionElement function, NodeList parameters, Node body, A arg) {
3909 LocalFunctionElement function,
3910 NodeList parameters,
3911 Node body,
3912 A arg) {
3913 return bulkHandleFunctionDeclaration(node, arg); 2567 return bulkHandleFunctionDeclaration(node, arg);
3914 } 2568 }
3915 2569
3916 @override 2570 @override
3917 R visitStaticFunctionDeclaration( 2571 R visitStaticFunctionDeclaration(FunctionExpression node,
3918 FunctionExpression node, 2572 MethodElement function, NodeList parameters, Node body, A arg) {
3919 MethodElement function,
3920 NodeList parameters,
3921 Node body,
3922 A arg) {
3923 return bulkHandleFunctionDeclaration(node, arg); 2573 return bulkHandleFunctionDeclaration(node, arg);
3924 } 2574 }
3925 2575
3926 @override 2576 @override
3927 R visitStaticGetterDeclaration( 2577 R visitStaticGetterDeclaration(
3928 FunctionExpression node, 2578 FunctionExpression node, MethodElement getter, Node body, A arg) {
3929 MethodElement getter,
3930 Node body,
3931 A arg) {
3932 return bulkHandleFunctionDeclaration(node, arg); 2579 return bulkHandleFunctionDeclaration(node, arg);
3933 } 2580 }
3934 2581
3935 @override 2582 @override
3936 R visitStaticSetterDeclaration( 2583 R visitStaticSetterDeclaration(FunctionExpression node, MethodElement setter,
3937 FunctionExpression node, 2584 NodeList parameters, Node body, A arg) {
3938 MethodElement setter,
3939 NodeList parameters,
3940 Node body,
3941 A arg) {
3942 return bulkHandleFunctionDeclaration(node, arg); 2585 return bulkHandleFunctionDeclaration(node, arg);
3943 } 2586 }
3944 2587
3945 @override 2588 @override
3946 R visitTopLevelFunctionDeclaration( 2589 R visitTopLevelFunctionDeclaration(FunctionExpression node,
3947 FunctionExpression node, 2590 MethodElement function, NodeList parameters, Node body, A arg) {
3948 MethodElement function,
3949 NodeList parameters,
3950 Node body,
3951 A arg) {
3952 return bulkHandleFunctionDeclaration(node, arg); 2591 return bulkHandleFunctionDeclaration(node, arg);
3953 } 2592 }
3954 2593
3955 @override 2594 @override
3956 R visitTopLevelGetterDeclaration( 2595 R visitTopLevelGetterDeclaration(
3957 FunctionExpression node, 2596 FunctionExpression node, MethodElement getter, Node body, A arg) {
3958 MethodElement getter,
3959 Node body,
3960 A arg) {
3961 return bulkHandleFunctionDeclaration(node, arg); 2597 return bulkHandleFunctionDeclaration(node, arg);
3962 } 2598 }
3963 2599
3964 @override 2600 @override
3965 R visitTopLevelSetterDeclaration( 2601 R visitTopLevelSetterDeclaration(FunctionExpression node,
3966 FunctionExpression node, 2602 MethodElement setter, NodeList parameters, Node body, A arg) {
3967 MethodElement setter,
3968 NodeList parameters,
3969 Node body,
3970 A arg) {
3971 return bulkHandleFunctionDeclaration(node, arg); 2603 return bulkHandleFunctionDeclaration(node, arg);
3972 } 2604 }
3973 } 2605 }
3974 2606
3975 /// Mixin that implements all variable/field declaration visitor methods of 2607 /// Mixin that implements all variable/field declaration visitor methods of
3976 /// [SemanticDeclarationVisitor] by delegating to a bulk handler. 2608 /// [SemanticDeclarationVisitor] by delegating to a bulk handler.
3977 /// 2609 ///
3978 /// Use this mixin to provide a trivial implementation for these methods. 2610 /// Use this mixin to provide a trivial implementation for these methods.
3979 abstract class VariableBulkMixin<R, A> 2611 abstract class VariableBulkMixin<R, A>
3980 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> { 2612 implements SemanticDeclarationVisitor<R, A>, BulkHandle<R, A> {
3981
3982 R bulkHandleVariableDeclaration(VariableDefinitions node, A arg) { 2613 R bulkHandleVariableDeclaration(VariableDefinitions node, A arg) {
3983 return bulkHandleNode( 2614 return bulkHandleNode(node, "Variable declaration `#` unhandled.", arg);
3984 node, "Variable declaration `#` unhandled.", arg);
3985 } 2615 }
3986 2616
3987 @override 2617 @override
3988 R visitInstanceFieldDeclaration( 2618 R visitInstanceFieldDeclaration(VariableDefinitions node, Node definition,
3989 VariableDefinitions node, 2619 FieldElement field, Node initializer, A arg) {
3990 Node definition,
3991 FieldElement field,
3992 Node initializer,
3993 A arg) {
3994 return bulkHandleVariableDeclaration(node, arg); 2620 return bulkHandleVariableDeclaration(node, arg);
3995 } 2621 }
3996 2622
3997 @override 2623 @override
3998 R visitLocalConstantDeclaration( 2624 R visitLocalConstantDeclaration(VariableDefinitions node, Node definition,
3999 VariableDefinitions node, 2625 LocalVariableElement variable, ConstantExpression constant, A arg) {
4000 Node definition,
4001 LocalVariableElement variable,
4002 ConstantExpression constant,
4003 A arg) {
4004 return bulkHandleVariableDeclaration(node, arg); 2626 return bulkHandleVariableDeclaration(node, arg);
4005 } 2627 }
4006 2628
4007 @override 2629 @override
4008 R visitLocalVariableDeclaration( 2630 R visitLocalVariableDeclaration(VariableDefinitions node, Node definition,
4009 VariableDefinitions node, 2631 LocalVariableElement variable, Node initializer, A arg) {
4010 Node definition,
4011 LocalVariableElement variable,
4012 Node initializer,
4013 A arg) {
4014 return bulkHandleVariableDeclaration(node, arg); 2632 return bulkHandleVariableDeclaration(node, arg);
4015 } 2633 }
4016 2634
4017 @override 2635 @override
4018 R visitStaticConstantDeclaration( 2636 R visitStaticConstantDeclaration(VariableDefinitions node, Node definition,
4019 VariableDefinitions node, 2637 FieldElement field, ConstantExpression constant, A arg) {
4020 Node definition,
4021 FieldElement field,
4022 ConstantExpression constant,
4023 A arg) {
4024 return bulkHandleVariableDeclaration(node, arg); 2638 return bulkHandleVariableDeclaration(node, arg);
4025 } 2639 }
4026 2640
4027 @override 2641 @override
4028 R visitStaticFieldDeclaration( 2642 R visitStaticFieldDeclaration(VariableDefinitions node, Node definition,
4029 VariableDefinitions node, 2643 FieldElement field, Node initializer, A arg) {
4030 Node definition,
4031 FieldElement field,
4032 Node initializer,
4033 A arg) {
4034 return bulkHandleVariableDeclaration(node, arg); 2644 return bulkHandleVariableDeclaration(node, arg);
4035 } 2645 }
4036 2646
4037 @override 2647 @override
4038 R visitTopLevelConstantDeclaration( 2648 R visitTopLevelConstantDeclaration(VariableDefinitions node, Node definition,
4039 VariableDefinitions node, 2649 FieldElement field, ConstantExpression constant, A arg) {
4040 Node definition,
4041 FieldElement field,
4042 ConstantExpression constant,
4043 A arg) {
4044 return bulkHandleVariableDeclaration(node, arg); 2650 return bulkHandleVariableDeclaration(node, arg);
4045 } 2651 }
4046 2652
4047 @override 2653 @override
4048 R visitTopLevelFieldDeclaration( 2654 R visitTopLevelFieldDeclaration(VariableDefinitions node, Node definition,
4049 VariableDefinitions node, 2655 FieldElement field, Node initializer, A arg) {
4050 Node definition,
4051 FieldElement field,
4052 Node initializer,
4053 A arg) {
4054 return bulkHandleVariableDeclaration(node, arg); 2656 return bulkHandleVariableDeclaration(node, arg);
4055 } 2657 }
4056 } 2658 }
4057 2659
4058 /// Visitor that implements [SemanticDeclarationVisitor] by the use of `BulkX` 2660 /// Visitor that implements [SemanticDeclarationVisitor] by the use of `BulkX`
4059 /// mixins. 2661 /// mixins.
4060 /// 2662 ///
4061 /// This class is useful in itself, but shows how to use the `BulkX` mixins and 2663 /// This class is useful in itself, but shows how to use the `BulkX` mixins and
4062 /// tests that the union of the `BulkX` mixins implement all `visit` and `error` 2664 /// tests that the union of the `BulkX` mixins implement all `visit` and `error`
4063 /// methods of [SemanticDeclarationVisitor]. 2665 /// methods of [SemanticDeclarationVisitor].
4064 class BulkDeclarationVisitor<R, A> extends SemanticDeclarationVisitor<R, A> 2666 class BulkDeclarationVisitor<R, A> extends SemanticDeclarationVisitor<R, A>
4065 with ConstructorBulkMixin<R, A>, 2667 with
4066 FunctionBulkMixin<R, A>, 2668 ConstructorBulkMixin<R, A>,
4067 VariableBulkMixin<R, A>, 2669 FunctionBulkMixin<R, A>,
4068 ParameterBulkMixin<R, A>, 2670 VariableBulkMixin<R, A>,
4069 InitializerBulkMixin<R, A> { 2671 ParameterBulkMixin<R, A>,
2672 InitializerBulkMixin<R, A> {
4070 @override 2673 @override
4071 R apply(Node node, A arg) { 2674 R apply(Node node, A arg) {
4072 throw new UnimplementedError("BulkDeclVisitor.apply unimplemented"); 2675 throw new UnimplementedError("BulkDeclVisitor.apply unimplemented");
4073 } 2676 }
4074 2677
4075 @override 2678 @override
4076 R bulkHandleNode(Node node, String message, A arg) { 2679 R bulkHandleNode(Node node, String message, A arg) {
4077 throw new UnimplementedError( 2680 throw new UnimplementedError(
4078 "BulkDeclVisitor.bulkHandleNode unimplemented"); 2681 "BulkDeclVisitor.bulkHandleNode unimplemented");
4079 } 2682 }
4080 2683
4081 @override 2684 @override
4082 applyInitializers(FunctionExpression constructor, A arg) { 2685 applyInitializers(FunctionExpression constructor, A arg) {
4083 throw new UnimplementedError( 2686 throw new UnimplementedError(
4084 "BulkDeclVisitor.applyInitializers unimplemented"); 2687 "BulkDeclVisitor.applyInitializers unimplemented");
4085 } 2688 }
4086 2689
4087 @override 2690 @override
4088 applyParameters(NodeList parameters, A arg) { 2691 applyParameters(NodeList parameters, A arg) {
4089 throw new UnimplementedError( 2692 throw new UnimplementedError(
4090 "BulkDeclVisitor.applyParameters unimplemented"); 2693 "BulkDeclVisitor.applyParameters unimplemented");
4091 } 2694 }
4092 } 2695 }
4093 2696
4094
4095 /// [SemanticSendVisitor] that visits subnodes. 2697 /// [SemanticSendVisitor] that visits subnodes.
4096 class TraversalSendMixin<R, A> implements SemanticSendVisitor<R, A> { 2698 class TraversalSendMixin<R, A> implements SemanticSendVisitor<R, A> {
4097 @override 2699 @override
4098 R apply(Node node, A arg) { 2700 R apply(Node node, A arg) {
4099 throw new UnimplementedError("TraversalMixin.apply unimplemented"); 2701 throw new UnimplementedError("TraversalMixin.apply unimplemented");
4100 } 2702 }
4101 2703
4102 @override 2704 @override
4103 void previsitDeferredAccess( 2705 void previsitDeferredAccess(Send node, PrefixElement prefix, A arg) {}
4104 Send node, 2706
4105 PrefixElement prefix, 2707 @override
4106 A arg) { 2708 R errorInvalidCompound(Send node, ErroneousElement error,
4107 } 2709 AssignmentOperator operator, Node rhs, A arg) {
4108 2710 apply(rhs, arg);
4109 @override 2711 return null;
4110 R errorInvalidCompound( 2712 }
4111 Send node, 2713
4112 ErroneousElement error, 2714 @override
4113 AssignmentOperator operator, 2715 R errorInvalidGet(Send node, ErroneousElement error, A arg) {
4114 Node rhs, 2716 return null;
4115 A arg) { 2717 }
4116 apply(rhs, arg); 2718
4117 return null; 2719 @override
4118 } 2720 R errorInvalidInvoke(Send node, ErroneousElement error, NodeList arguments,
4119 2721 Selector selector, A arg) {
4120 @override
4121 R errorInvalidGet(
4122 Send node,
4123 ErroneousElement error,
4124 A arg) {
4125 return null;
4126 }
4127
4128 @override
4129 R errorInvalidInvoke(
4130 Send node,
4131 ErroneousElement error,
4132 NodeList arguments,
4133 Selector selector,
4134 A arg) {
4135 apply(arguments, arg); 2722 apply(arguments, arg);
4136 return null; 2723 return null;
4137 } 2724 }
4138 2725
4139 @override 2726 @override
4140 R errorInvalidPostfix( 2727 R errorInvalidPostfix(
4141 Send node, 2728 Send node, ErroneousElement error, IncDecOperator operator, A arg) {
4142 ErroneousElement error,
4143 IncDecOperator operator,
4144 A arg) {
4145 return null; 2729 return null;
4146 } 2730 }
4147 2731
4148 @override 2732 @override
4149 R errorInvalidPrefix( 2733 R errorInvalidPrefix(
4150 Send node, 2734 Send node, ErroneousElement error, IncDecOperator operator, A arg) {
4151 ErroneousElement error, 2735 return null;
4152 IncDecOperator operator, 2736 }
4153 A arg) { 2737
4154 return null; 2738 @override
4155 } 2739 R errorInvalidSet(Send node, ErroneousElement error, Node rhs, A arg) {
4156
4157 @override
4158 R errorInvalidSet(
4159 Send node,
4160 ErroneousElement error,
4161 Node rhs,
4162 A arg) {
4163 apply(rhs, arg); 2740 apply(rhs, arg);
4164 return null; 2741 return null;
4165 } 2742 }
4166 2743
4167 @override 2744 @override
4168 R errorInvalidUnary( 2745 R errorInvalidUnary(
4169 Send node, 2746 Send node, UnaryOperator operator, ErroneousElement error, A arg) {
4170 UnaryOperator operator, 2747 return null;
4171 ErroneousElement error, 2748 }
4172 A arg) { 2749
4173 return null; 2750 @override
4174 } 2751 R errorInvalidEquals(Send node, ErroneousElement error, Node right, A arg) {
4175
4176 @override
4177 R errorInvalidEquals(
4178 Send node,
4179 ErroneousElement error,
4180 Node right,
4181 A arg) {
4182 apply(right, arg); 2752 apply(right, arg);
4183 return null; 2753 return null;
4184 } 2754 }
4185 2755
4186 @override 2756 @override
4187 R errorInvalidNotEquals( 2757 R errorInvalidNotEquals(
4188 Send node, 2758 Send node, ErroneousElement error, Node right, A arg) {
4189 ErroneousElement error,
4190 Node right,
4191 A arg) {
4192 apply(right, arg); 2759 apply(right, arg);
4193 return null; 2760 return null;
4194 } 2761 }
4195 2762
4196 @override 2763 @override
4197 R errorInvalidBinary( 2764 R errorInvalidBinary(Send node, ErroneousElement error,
4198 Send node, 2765 BinaryOperator operator, Node right, A arg) {
4199 ErroneousElement error,
4200 BinaryOperator operator,
4201 Node right,
4202 A arg) {
4203 apply(right, arg); 2766 apply(right, arg);
4204 return null; 2767 return null;
4205 } 2768 }
4206 2769
4207 @override 2770 @override
4208 R errorInvalidIndex( 2771 R errorInvalidIndex(Send node, ErroneousElement error, Node index, A arg) {
4209 Send node,
4210 ErroneousElement error,
4211 Node index,
4212 A arg) {
4213 apply(index, arg); 2772 apply(index, arg);
4214 return null; 2773 return null;
4215 } 2774 }
4216 2775
4217 @override 2776 @override
4218 R errorInvalidIndexSet( 2777 R errorInvalidIndexSet(
4219 Send node, 2778 Send node, ErroneousElement error, Node index, Node rhs, A arg) {
4220 ErroneousElement error, 2779 apply(index, arg);
4221 Node index, 2780 apply(rhs, arg);
4222 Node rhs, 2781 return null;
4223 A arg) { 2782 }
4224 apply(index, arg); 2783
4225 apply(rhs, arg); 2784 @override
4226 return null; 2785 R errorInvalidCompoundIndexSet(Send node, ErroneousElement error, Node index,
4227 } 2786 AssignmentOperator operator, Node rhs, A arg) {
4228 2787 apply(index, arg);
4229 @override 2788 apply(rhs, arg);
4230 R errorInvalidCompoundIndexSet( 2789 return null;
4231 Send node, 2790 }
4232 ErroneousElement error, 2791
4233 Node index, 2792 @override
4234 AssignmentOperator operator, 2793 R errorInvalidIndexPrefix(Send node, ErroneousElement error, Node index,
4235 Node rhs, 2794 IncDecOperator operator, A arg) {
4236 A arg) { 2795 apply(index, arg);
4237 apply(index, arg); 2796 return null;
4238 apply(rhs, arg); 2797 }
4239 return null; 2798
4240 } 2799 @override
4241 2800 R errorInvalidIndexPostfix(Send node, ErroneousElement error, Node index,
4242 @override 2801 IncDecOperator operator, A arg) {
4243 R errorInvalidIndexPrefix(
4244 Send node,
4245 ErroneousElement error,
4246 Node index,
4247 IncDecOperator operator,
4248 A arg) {
4249 apply(index, arg);
4250 return null;
4251 }
4252
4253 @override
4254 R errorInvalidIndexPostfix(
4255 Send node,
4256 ErroneousElement error,
4257 Node index,
4258 IncDecOperator operator,
4259 A arg) {
4260 apply(index, arg); 2802 apply(index, arg);
4261 return null; 2803 return null;
4262 } 2804 }
4263 2805
4264 @override 2806 @override
4265 R visitClassTypeLiteralSet( 2807 R visitClassTypeLiteralSet(
4266 SendSet node, 2808 SendSet node, ConstantExpression constant, Node rhs, A arg) {
4267 ConstantExpression constant,
4268 Node rhs,
4269 A arg) {
4270 apply(rhs, arg); 2809 apply(rhs, arg);
4271 return null; 2810 return null;
4272 } 2811 }
4273 2812
4274 @override 2813 @override
4275 R visitDynamicTypeLiteralSet( 2814 R visitDynamicTypeLiteralSet(
4276 SendSet node, 2815 SendSet node, ConstantExpression constant, Node rhs, A arg) {
4277 ConstantExpression constant, 2816 apply(rhs, arg);
4278 Node rhs, 2817 return null;
4279 A arg) { 2818 }
4280 apply(rhs, arg); 2819
4281 return null; 2820 @override
4282 } 2821 R visitFinalLocalVariableCompound(Send node, LocalVariableElement variable,
4283 2822 AssignmentOperator operator, Node rhs, A arg) {
4284 @override
4285 R visitFinalLocalVariableCompound(
4286 Send node,
4287 LocalVariableElement variable,
4288 AssignmentOperator operator,
4289 Node rhs,
4290 A arg) {
4291 apply(rhs, arg); 2823 apply(rhs, arg);
4292 return null; 2824 return null;
4293 } 2825 }
4294 2826
4295 @override 2827 @override
4296 R visitFinalLocalVariableSet( 2828 R visitFinalLocalVariableSet(
4297 SendSet node, 2829 SendSet node, LocalVariableElement variable, Node rhs, A arg) {
4298 LocalVariableElement variable, 2830 apply(rhs, arg);
4299 Node rhs, 2831 return null;
4300 A arg) { 2832 }
4301 apply(rhs, arg); 2833
4302 return null; 2834 @override
4303 } 2835 R visitFinalParameterCompound(Send node, ParameterElement parameter,
4304 2836 AssignmentOperator operator, Node rhs, A arg) {
4305 @override
4306 R visitFinalParameterCompound(
4307 Send node,
4308 ParameterElement parameter,
4309 AssignmentOperator operator,
4310 Node rhs,
4311 A arg) {
4312 apply(rhs, arg); 2837 apply(rhs, arg);
4313 return null; 2838 return null;
4314 } 2839 }
4315 2840
4316 @override 2841 @override
4317 R visitFinalParameterSet( 2842 R visitFinalParameterSet(
4318 SendSet node, 2843 SendSet node, ParameterElement parameter, Node rhs, A arg) {
4319 ParameterElement parameter, 2844 apply(rhs, arg);
4320 Node rhs, 2845 return null;
4321 A arg) { 2846 }
4322 apply(rhs, arg); 2847
4323 return null; 2848 @override
4324 } 2849 R visitFinalStaticFieldCompound(Send node, FieldElement field,
4325 2850 AssignmentOperator operator, Node rhs, A arg) {
4326 @override
4327 R visitFinalStaticFieldCompound(
4328 Send node,
4329 FieldElement field,
4330 AssignmentOperator operator,
4331 Node rhs,
4332 A arg) {
4333 apply(rhs, arg); 2851 apply(rhs, arg);
4334 return null; 2852 return null;
4335 } 2853 }
4336 2854
4337 @override 2855 @override
4338 R visitFinalStaticFieldSet( 2856 R visitFinalStaticFieldSet(
4339 SendSet node, 2857 SendSet node, FieldElement field, Node rhs, A arg) {
4340 FieldElement field, 2858 apply(rhs, arg);
4341 Node rhs, 2859 return null;
4342 A arg) { 2860 }
4343 apply(rhs, arg); 2861
4344 return null; 2862 @override
4345 } 2863 R visitFinalSuperFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
4346 2864 apply(rhs, arg);
4347 @override 2865 return null;
4348 R visitFinalSuperFieldSet( 2866 }
4349 SendSet node, 2867
4350 FieldElement field, 2868 @override
4351 Node rhs, 2869 R visitFinalTopLevelFieldCompound(Send node, FieldElement field,
4352 A arg) { 2870 AssignmentOperator operator, Node rhs, A arg) {
4353 apply(rhs, arg);
4354 return null;
4355 }
4356
4357 @override
4358 R visitFinalTopLevelFieldCompound(
4359 Send node,
4360 FieldElement field,
4361 AssignmentOperator operator,
4362 Node rhs,
4363 A arg) {
4364 apply(rhs, arg); 2871 apply(rhs, arg);
4365 return null; 2872 return null;
4366 } 2873 }
4367 2874
4368 @override 2875 @override
4369 R visitFinalTopLevelFieldSet( 2876 R visitFinalTopLevelFieldSet(
4370 SendSet node, 2877 SendSet node, FieldElement field, Node rhs, A arg) {
4371 FieldElement field, 2878 apply(rhs, arg);
4372 Node rhs, 2879 return null;
4373 A arg) { 2880 }
4374 apply(rhs, arg); 2881
4375 return null; 2882 @override
4376 } 2883 R visitLocalFunctionCompound(Send node, LocalFunctionElement function,
4377 2884 AssignmentOperator operator, Node rhs, A arg) {
4378 @override 2885 apply(rhs, arg);
4379 R visitLocalFunctionCompound( 2886 return null;
4380 Send node, 2887 }
4381 LocalFunctionElement function, 2888
4382 AssignmentOperator operator, 2889 @override
4383 Node rhs, 2890 R visitLocalFunctionPostfix(Send node, LocalFunctionElement function,
4384 A arg) { 2891 IncDecOperator operator, A arg) {
4385 apply(rhs, arg); 2892 return null;
4386 return null; 2893 }
4387 } 2894
4388 2895 @override
4389 @override 2896 R visitLocalFunctionPrefix(Send node, LocalFunctionElement function,
4390 R visitLocalFunctionPostfix( 2897 IncDecOperator operator, A arg) {
4391 Send node,
4392 LocalFunctionElement function,
4393 IncDecOperator operator,
4394 A arg) {
4395 return null;
4396 }
4397
4398 @override
4399 R visitLocalFunctionPrefix(
4400 Send node,
4401 LocalFunctionElement function,
4402 IncDecOperator operator,
4403 A arg) {
4404 return null; 2898 return null;
4405 } 2899 }
4406 2900
4407 @override 2901 @override
4408 R visitLocalFunctionSet( 2902 R visitLocalFunctionSet(
4409 SendSet node, 2903 SendSet node, LocalFunctionElement function, Node rhs, A arg) {
4410 LocalFunctionElement function, 2904 apply(rhs, arg);
4411 Node rhs, 2905 return null;
4412 A arg) { 2906 }
4413 apply(rhs, arg); 2907
4414 return null; 2908 @override
4415 } 2909 R visitStaticFunctionSet(Send node, MethodElement function, Node rhs, A arg) {
4416
4417 @override
4418 R visitStaticFunctionSet(
4419 Send node,
4420 MethodElement function,
4421 Node rhs,
4422 A arg) {
4423 apply(rhs, arg); 2910 apply(rhs, arg);
4424 return null; 2911 return null;
4425 } 2912 }
4426 2913
4427 @override 2914 @override
4428 R visitStaticGetterSet( 2915 R visitStaticGetterSet(
4429 SendSet node, 2916 SendSet node, FunctionElement getter, Node rhs, A arg) {
4430 FunctionElement getter, 2917 apply(rhs, arg);
4431 Node rhs, 2918 return null;
4432 A arg) { 2919 }
4433 apply(rhs, arg); 2920
4434 return null; 2921 @override
4435 } 2922 R visitStaticSetterGet(Send node, FunctionElement setter, A arg) {
4436 2923 return null;
4437 @override 2924 }
4438 R visitStaticSetterGet( 2925
4439 Send node, 2926 @override
4440 FunctionElement setter, 2927 R visitStaticSetterInvoke(Send node, FunctionElement setter,
4441 A arg) { 2928 NodeList arguments, CallStructure callStructure, A arg) {
4442 return null; 2929 apply(arguments, arg);
4443 } 2930 return null;
4444 2931 }
4445 @override 2932
4446 R visitStaticSetterInvoke( 2933 @override
4447 Send node, 2934 R visitSuperGetterSet(SendSet node, FunctionElement getter, Node rhs, A arg) {
4448 FunctionElement setter, 2935 apply(rhs, arg);
4449 NodeList arguments, 2936 return null;
4450 CallStructure callStructure, 2937 }
4451 A arg) { 2938
4452 apply(arguments, arg); 2939 @override
4453 return null; 2940 R visitSuperMethodSet(Send node, MethodElement method, Node rhs, A arg) {
4454 } 2941 apply(rhs, arg);
4455 2942 return null;
4456 @override 2943 }
4457 R visitSuperGetterSet( 2944
4458 SendSet node, 2945 @override
4459 FunctionElement getter, 2946 R visitSuperSetterGet(Send node, FunctionElement setter, A arg) {
4460 Node rhs, 2947 return null;
4461 A arg) { 2948 }
4462 apply(rhs, arg); 2949
4463 return null; 2950 @override
4464 } 2951 R visitSuperSetterInvoke(Send node, FunctionElement setter,
4465 2952 NodeList arguments, CallStructure callStructure, A arg) {
4466 @override
4467 R visitSuperMethodSet(
4468 Send node,
4469 MethodElement method,
4470 Node rhs,
4471 A arg) {
4472 apply(rhs, arg);
4473 return null;
4474 }
4475
4476 @override
4477 R visitSuperSetterGet(
4478 Send node,
4479 FunctionElement setter,
4480 A arg) {
4481 return null;
4482 }
4483
4484 @override
4485 R visitSuperSetterInvoke(
4486 Send node,
4487 FunctionElement setter,
4488 NodeList arguments,
4489 CallStructure callStructure,
4490 A arg) {
4491 apply(arguments, arg); 2953 apply(arguments, arg);
4492 return null; 2954 return null;
4493 } 2955 }
4494 2956
4495 @override 2957 @override
4496 R visitTopLevelFunctionSet( 2958 R visitTopLevelFunctionSet(
4497 Send node, 2959 Send node, MethodElement function, Node rhs, A arg) {
4498 MethodElement function,
4499 Node rhs,
4500 A arg) {
4501 apply(rhs, arg); 2960 apply(rhs, arg);
4502 return null; 2961 return null;
4503 } 2962 }
4504 2963
4505 @override 2964 @override
4506 R visitTopLevelGetterSet( 2965 R visitTopLevelGetterSet(
4507 SendSet node, 2966 SendSet node, FunctionElement getter, Node rhs, A arg) {
4508 FunctionElement getter, 2967 apply(rhs, arg);
4509 Node rhs, 2968 return null;
4510 A arg) { 2969 }
4511 apply(rhs, arg); 2970
4512 return null; 2971 @override
4513 } 2972 R visitTopLevelSetterGet(Send node, FunctionElement setter, A arg) {
4514 2973 return null;
4515 @override 2974 }
4516 R visitTopLevelSetterGet( 2975
4517 Send node, 2976 @override
4518 FunctionElement setter, 2977 R visitTopLevelSetterInvoke(Send node, FunctionElement setter,
4519 A arg) { 2978 NodeList arguments, CallStructure callStructure, A arg) {
4520 return null;
4521 }
4522
4523 @override
4524 R visitTopLevelSetterInvoke(
4525 Send node,
4526 FunctionElement setter,
4527 NodeList arguments,
4528 CallStructure callStructure,
4529 A arg) {
4530 apply(arguments, arg); 2979 apply(arguments, arg);
4531 return null; 2980 return null;
4532 } 2981 }
4533 2982
4534 @override 2983 @override
4535 R visitTypeVariableTypeLiteralSet( 2984 R visitTypeVariableTypeLiteralSet(
4536 SendSet node, 2985 SendSet node, TypeVariableElement element, Node rhs, A arg) {
4537 TypeVariableElement element,
4538 Node rhs,
4539 A arg) {
4540 apply(rhs, arg); 2986 apply(rhs, arg);
4541 return null; 2987 return null;
4542 } 2988 }
4543 2989
4544 @override 2990 @override
4545 R visitTypedefTypeLiteralSet( 2991 R visitTypedefTypeLiteralSet(
4546 SendSet node, 2992 SendSet node, ConstantExpression constant, Node rhs, A arg) {
4547 ConstantExpression constant, 2993 apply(rhs, arg);
4548 Node rhs, 2994 return null;
4549 A arg) { 2995 }
4550 apply(rhs, arg); 2996
4551 return null; 2997 @override
4552 } 2998 R visitUnresolvedSuperIndex(Send node, Element function, Node index, A arg) {
4553 2999 apply(index, arg);
4554 @override 3000 return null;
4555 R visitUnresolvedSuperIndex( 3001 }
4556 Send node, 3002
4557 Element function, 3003 @override
4558 Node index, 3004 R visitUnresolvedSuperGet(Send node, Element element, A arg) {
4559 A arg) { 3005 return null;
4560 apply(index, arg); 3006 }
4561 return null; 3007
4562 } 3008 @override
4563 3009 R visitUnresolvedSuperSet(Send node, Element element, Node rhs, A arg) {
4564 @override 3010 apply(rhs, arg);
4565 R visitUnresolvedSuperGet( 3011 return null;
4566 Send node, 3012 }
4567 Element element, 3013
4568 A arg) { 3014 @override
4569 return null; 3015 R visitUnresolvedSuperInvoke(Send node, Element function, NodeList arguments,
4570 } 3016 Selector selector, A arg) {
4571 3017 apply(arguments, arg);
4572 @override 3018 return null;
4573 R visitUnresolvedSuperSet( 3019 }
4574 Send node, 3020
4575 Element element, 3021 @override
4576 Node rhs, 3022 R visitAs(Send node, Node expression, DartType type, A arg) {
4577 A arg) {
4578 apply(rhs, arg);
4579 return null;
4580 }
4581
4582 @override
4583 R visitUnresolvedSuperInvoke(
4584 Send node,
4585 Element function,
4586 NodeList arguments,
4587 Selector selector,
4588 A arg) {
4589 apply(arguments, arg);
4590 return null;
4591 }
4592
4593 @override
4594 R visitAs(
4595 Send node,
4596 Node expression,
4597 DartType type,
4598 A arg) {
4599 apply(expression, arg); 3023 apply(expression, arg);
4600 return null; 3024 return null;
4601 } 3025 }
4602 3026
4603 @override 3027 @override
4604 R visitBinary( 3028 R visitBinary(
4605 Send node, 3029 Send node, Node left, BinaryOperator operator, Node right, A arg) {
4606 Node left,
4607 BinaryOperator operator,
4608 Node right,
4609 A arg) {
4610 apply(left, arg); 3030 apply(left, arg);
4611 apply(right, arg); 3031 apply(right, arg);
4612 return null; 3032 return null;
4613 } 3033 }
4614 3034
4615 @override 3035 @override
4616 R visitClassTypeLiteralCompound( 3036 R visitClassTypeLiteralCompound(Send node, ConstantExpression constant,
4617 Send node, 3037 AssignmentOperator operator, Node rhs, A arg) {
4618 ConstantExpression constant, 3038 apply(rhs, arg);
4619 AssignmentOperator operator, 3039 return null;
4620 Node rhs, 3040 }
4621 A arg) { 3041
4622 apply(rhs, arg); 3042 @override
4623 return null; 3043 R visitClassTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
4624 } 3044 return null;
4625 3045 }
4626 @override 3046
4627 R visitClassTypeLiteralGet( 3047 @override
4628 Send node, 3048 R visitClassTypeLiteralInvoke(Send node, ConstantExpression constant,
4629 ConstantExpression constant, 3049 NodeList arguments, CallStructure callStructure, A arg) {
4630 A arg) {
4631 return null;
4632 }
4633
4634 @override
4635 R visitClassTypeLiteralInvoke(
4636 Send node,
4637 ConstantExpression constant,
4638 NodeList arguments,
4639 CallStructure callStructure,
4640 A arg) {
4641 apply(arguments, arg); 3050 apply(arguments, arg);
4642 return null; 3051 return null;
4643 } 3052 }
4644 3053
4645 @override 3054 @override
4646 R visitClassTypeLiteralPostfix( 3055 R visitClassTypeLiteralPostfix(
4647 Send node, 3056 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
4648 ConstantExpression constant,
4649 IncDecOperator operator,
4650 A arg) {
4651 return null; 3057 return null;
4652 } 3058 }
4653 3059
4654 @override 3060 @override
4655 R visitClassTypeLiteralPrefix( 3061 R visitClassTypeLiteralPrefix(
4656 Send node, 3062 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
4657 ConstantExpression constant, 3063 return null;
4658 IncDecOperator operator, 3064 }
4659 A arg) { 3065
4660 return null; 3066 @override
4661 } 3067 R visitCompoundIndexSet(SendSet node, Node receiver, Node index,
4662 3068 AssignmentOperator operator, Node rhs, A arg) {
4663 @override
4664 R visitCompoundIndexSet(
4665 SendSet node,
4666 Node receiver,
4667 Node index,
4668 AssignmentOperator operator,
4669 Node rhs,
4670 A arg) {
4671 apply(receiver, arg); 3069 apply(receiver, arg);
4672 apply(index, arg); 3070 apply(index, arg);
4673 apply(rhs, arg); 3071 apply(rhs, arg);
4674 return null; 3072 return null;
4675 } 3073 }
4676 3074
4677 @override 3075 @override
4678 R visitConstantGet( 3076 R visitConstantGet(Send node, ConstantExpression constant, A arg) {
4679 Send node,
4680 ConstantExpression constant,
4681 A arg) {
4682 return null; 3077 return null;
4683 } 3078 }
4684 3079
4685 @override 3080 @override
4686 R visitConstantInvoke( 3081 R visitConstantInvoke(Send node, ConstantExpression constant,
4687 Send node, 3082 NodeList arguments, CallStructure callStructure, A arg) {
4688 ConstantExpression constant,
4689 NodeList arguments,
4690 CallStructure callStructure,
4691 A arg) {
4692 apply(arguments, arg); 3083 apply(arguments, arg);
4693 return null; 3084 return null;
4694 } 3085 }
4695 3086
4696 @override 3087 @override
4697 R visitDynamicPropertyCompound( 3088 R visitDynamicPropertyCompound(Send node, Node receiver, Name name,
4698 Send node, 3089 AssignmentOperator operator, Node rhs, A arg) {
4699 Node receiver,
4700 Name name,
4701 AssignmentOperator operator,
4702 Node rhs,
4703 A arg) {
4704 apply(receiver, arg); 3090 apply(receiver, arg);
4705 apply(rhs, arg); 3091 apply(rhs, arg);
4706 return null; 3092 return null;
4707 } 3093 }
4708 3094
4709 @override 3095 @override
4710 R visitIfNotNullDynamicPropertyCompound( 3096 R visitIfNotNullDynamicPropertyCompound(Send node, Node receiver, Name name,
4711 Send node, 3097 AssignmentOperator operator, Node rhs, A arg) {
4712 Node receiver,
4713 Name name,
4714 AssignmentOperator operator,
4715 Node rhs,
4716 A arg) {
4717 apply(receiver, arg); 3098 apply(receiver, arg);
4718 apply(rhs, arg); 3099 apply(rhs, arg);
4719 return null; 3100 return null;
4720 } 3101 }
4721 3102
4722 @override 3103 @override
4723 R visitDynamicPropertyGet( 3104 R visitDynamicPropertyGet(Send node, Node receiver, Name name, A arg) {
4724 Send node,
4725 Node receiver,
4726 Name name,
4727 A arg) {
4728 apply(receiver, arg); 3105 apply(receiver, arg);
4729 return null; 3106 return null;
4730 } 3107 }
4731 3108
4732 @override 3109 @override
4733 R visitIfNotNullDynamicPropertyGet( 3110 R visitIfNotNullDynamicPropertyGet(
4734 Send node, 3111 Send node, Node receiver, Name name, A arg) {
4735 Node receiver,
4736 Name name,
4737 A arg) {
4738 apply(receiver, arg); 3112 apply(receiver, arg);
4739 return null; 3113 return null;
4740 } 3114 }
4741 3115
4742 @override 3116 @override
4743 R visitDynamicPropertyInvoke( 3117 R visitDynamicPropertyInvoke(
4744 Send node, 3118 Send node, Node receiver, NodeList arguments, Selector selector, A arg) {
4745 Node receiver,
4746 NodeList arguments,
4747 Selector selector,
4748 A arg) {
4749 apply(receiver, arg); 3119 apply(receiver, arg);
4750 apply(arguments, arg); 3120 apply(arguments, arg);
4751 return null; 3121 return null;
4752 } 3122 }
4753 3123
4754 @override 3124 @override
4755 R visitIfNotNullDynamicPropertyInvoke( 3125 R visitIfNotNullDynamicPropertyInvoke(
4756 Send node, 3126 Send node, Node receiver, NodeList arguments, Selector selector, A arg) {
4757 Node receiver,
4758 NodeList arguments,
4759 Selector selector,
4760 A arg) {
4761 apply(receiver, arg); 3127 apply(receiver, arg);
4762 apply(arguments, arg); 3128 apply(arguments, arg);
4763 return null; 3129 return null;
4764 } 3130 }
4765 3131
4766 @override 3132 @override
4767 R visitDynamicPropertyPostfix( 3133 R visitDynamicPropertyPostfix(
4768 Send node, 3134 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
4769 Node receiver,
4770 Name name,
4771 IncDecOperator operator,
4772 A arg) {
4773 apply(receiver, arg); 3135 apply(receiver, arg);
4774 return null; 3136 return null;
4775 } 3137 }
4776 3138
4777 @override 3139 @override
4778 R visitIfNotNullDynamicPropertyPostfix( 3140 R visitIfNotNullDynamicPropertyPostfix(
4779 Send node, 3141 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
4780 Node receiver,
4781 Name name,
4782 IncDecOperator operator,
4783 A arg) {
4784 apply(receiver, arg); 3142 apply(receiver, arg);
4785 return null; 3143 return null;
4786 } 3144 }
4787 3145
4788 @override 3146 @override
4789 R visitDynamicPropertyPrefix( 3147 R visitDynamicPropertyPrefix(
4790 Send node, 3148 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
4791 Node receiver,
4792 Name name,
4793 IncDecOperator operator,
4794 A arg) {
4795 apply(receiver, arg); 3149 apply(receiver, arg);
4796 return null; 3150 return null;
4797 } 3151 }
4798 3152
4799 @override 3153 @override
4800 R visitIfNotNullDynamicPropertyPrefix( 3154 R visitIfNotNullDynamicPropertyPrefix(
4801 Send node, 3155 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
4802 Node receiver,
4803 Name name,
4804 IncDecOperator operator,
4805 A arg) {
4806 apply(receiver, arg); 3156 apply(receiver, arg);
4807 return null; 3157 return null;
4808 } 3158 }
4809 3159
4810 @override 3160 @override
4811 R visitDynamicPropertySet( 3161 R visitDynamicPropertySet(
4812 SendSet node, 3162 SendSet node, Node receiver, Name name, Node rhs, A arg) {
4813 Node receiver,
4814 Name name,
4815 Node rhs,
4816 A arg) {
4817 apply(receiver, arg); 3163 apply(receiver, arg);
4818 apply(rhs, arg); 3164 apply(rhs, arg);
4819 return null; 3165 return null;
4820 } 3166 }
4821 3167
4822 @override 3168 @override
4823 R visitIfNotNullDynamicPropertySet( 3169 R visitIfNotNullDynamicPropertySet(
4824 SendSet node, 3170 SendSet node, Node receiver, Name name, Node rhs, A arg) {
4825 Node receiver,
4826 Name name,
4827 Node rhs,
4828 A arg) {
4829 apply(receiver, arg); 3171 apply(receiver, arg);
4830 apply(rhs, arg); 3172 apply(rhs, arg);
4831 return null; 3173 return null;
4832 } 3174 }
4833 3175
4834 @override 3176 @override
4835 R visitDynamicTypeLiteralCompound( 3177 R visitDynamicTypeLiteralCompound(Send node, ConstantExpression constant,
4836 Send node, 3178 AssignmentOperator operator, Node rhs, A arg) {
4837 ConstantExpression constant,
4838 AssignmentOperator operator,
4839 Node rhs,
4840 A arg) {
4841 apply(rhs, arg); 3179 apply(rhs, arg);
4842 return null; 3180 return null;
4843 } 3181 }
4844 3182
4845 @override 3183 @override
4846 R visitDynamicTypeLiteralGet( 3184 R visitDynamicTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
4847 Send node,
4848 ConstantExpression constant,
4849 A arg) {
4850 return null; 3185 return null;
4851 } 3186 }
4852 3187
4853 @override 3188 @override
4854 R visitDynamicTypeLiteralInvoke( 3189 R visitDynamicTypeLiteralInvoke(Send node, ConstantExpression constant,
4855 Send node, 3190 NodeList arguments, CallStructure callStructure, A arg) {
4856 ConstantExpression constant,
4857 NodeList arguments,
4858 CallStructure callStructure,
4859 A arg) {
4860 apply(arguments, arg); 3191 apply(arguments, arg);
4861 return null; 3192 return null;
4862 } 3193 }
4863 3194
4864 @override 3195 @override
4865 R visitDynamicTypeLiteralPostfix( 3196 R visitDynamicTypeLiteralPostfix(
4866 Send node, 3197 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
4867 ConstantExpression constant,
4868 IncDecOperator operator,
4869 A arg) {
4870 return null; 3198 return null;
4871 } 3199 }
4872 3200
4873 @override 3201 @override
4874 R visitDynamicTypeLiteralPrefix( 3202 R visitDynamicTypeLiteralPrefix(
4875 Send node, 3203 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
4876 ConstantExpression constant,
4877 IncDecOperator operator,
4878 A arg) {
4879 return null; 3204 return null;
4880 } 3205 }
4881 3206
4882 @override 3207 @override
4883 R visitEquals( 3208 R visitEquals(Send node, Node left, Node right, A arg) {
4884 Send node,
4885 Node left,
4886 Node right,
4887 A arg) {
4888 apply(left, arg); 3209 apply(left, arg);
4889 apply(right, arg); 3210 apply(right, arg);
4890 return null; 3211 return null;
4891 } 3212 }
4892 3213
4893 @override 3214 @override
4894 R visitExpressionInvoke( 3215 R visitExpressionInvoke(Send node, Node expression, NodeList arguments,
4895 Send node, 3216 CallStructure callStructure, A arg) {
4896 Node expression,
4897 NodeList arguments,
4898 CallStructure callStructure,
4899 A arg) {
4900 apply(expression, arg); 3217 apply(expression, arg);
4901 apply(arguments, arg); 3218 apply(arguments, arg);
4902 return null; 3219 return null;
4903 } 3220 }
4904 3221
4905 @override 3222 @override
4906 R visitIndex( 3223 R visitIndex(Send node, Node receiver, Node index, A arg) {
4907 Send node,
4908 Node receiver,
4909 Node index,
4910 A arg) {
4911 apply(receiver, arg); 3224 apply(receiver, arg);
4912 apply(index, arg); 3225 apply(index, arg);
4913 return null; 3226 return null;
4914 } 3227 }
4915 3228
4916 @override 3229 @override
4917 R visitIndexSet( 3230 R visitIndexSet(SendSet node, Node receiver, Node index, Node rhs, A arg) {
4918 SendSet node,
4919 Node receiver,
4920 Node index,
4921 Node rhs,
4922 A arg) {
4923 apply(receiver, arg); 3231 apply(receiver, arg);
4924 apply(index, arg); 3232 apply(index, arg);
4925 apply(rhs, arg); 3233 apply(rhs, arg);
4926 return null; 3234 return null;
4927 } 3235 }
4928 3236
4929 @override 3237 @override
4930 R visitIs( 3238 R visitIs(Send node, Node expression, DartType type, A arg) {
4931 Send node,
4932 Node expression,
4933 DartType type,
4934 A arg) {
4935 apply(expression, arg); 3239 apply(expression, arg);
4936 return null; 3240 return null;
4937 } 3241 }
4938 3242
4939 @override 3243 @override
4940 R visitIsNot( 3244 R visitIsNot(Send node, Node expression, DartType type, A arg) {
4941 Send node,
4942 Node expression,
4943 DartType type,
4944 A arg) {
4945 apply(expression, arg); 3245 apply(expression, arg);
4946 return null; 3246 return null;
4947 } 3247 }
4948 3248
4949 @override 3249 @override
4950 R visitLocalFunctionGet( 3250 R visitLocalFunctionGet(Send node, LocalFunctionElement function, A arg) {
4951 Send node,
4952 LocalFunctionElement function,
4953 A arg) {
4954 return null; 3251 return null;
4955 } 3252 }
4956 3253
4957 @override 3254 @override
4958 R visitLocalFunctionInvoke( 3255 R visitLocalFunctionInvoke(Send node, LocalFunctionElement function,
4959 Send node, 3256 NodeList arguments, CallStructure callStructure, A arg) {
4960 LocalFunctionElement function,
4961 NodeList arguments,
4962 CallStructure callStructure,
4963 A arg) {
4964 apply(arguments, arg); 3257 apply(arguments, arg);
4965 return null; 3258 return null;
4966 } 3259 }
4967 3260
4968 @override 3261 @override
4969 R visitLocalFunctionIncompatibleInvoke( 3262 R visitLocalFunctionIncompatibleInvoke(
4970 Send node, 3263 Send node,
4971 LocalFunctionElement function, 3264 LocalFunctionElement function,
4972 NodeList arguments, 3265 NodeList arguments,
4973 CallStructure callStructure, 3266 CallStructure callStructure,
4974 A arg) { 3267 A arg) {
4975 apply(arguments, arg); 3268 apply(arguments, arg);
4976 return null; 3269 return null;
4977 } 3270 }
4978 3271
4979 @override 3272 @override
4980 R visitLocalVariableCompound( 3273 R visitLocalVariableCompound(Send node, LocalVariableElement variable,
4981 Send node, 3274 AssignmentOperator operator, Node rhs, A arg) {
4982 LocalVariableElement variable, 3275 apply(rhs, arg);
4983 AssignmentOperator operator, 3276 return null;
4984 Node rhs, 3277 }
4985 A arg) { 3278
4986 apply(rhs, arg); 3279 @override
4987 return null; 3280 R visitLocalVariableGet(Send node, LocalVariableElement variable, A arg) {
4988 } 3281 return null;
4989 3282 }
4990 @override 3283
4991 R visitLocalVariableGet( 3284 @override
4992 Send node, 3285 R visitLocalVariableInvoke(Send node, LocalVariableElement variable,
4993 LocalVariableElement variable, 3286 NodeList arguments, CallStructure callStructure, A arg) {
4994 A arg) { 3287 apply(arguments, arg);
4995 return null; 3288 return null;
4996 } 3289 }
4997 3290
4998 @override 3291 @override
4999 R visitLocalVariableInvoke( 3292 R visitLocalVariablePostfix(Send node, LocalVariableElement variable,
5000 Send node, 3293 IncDecOperator operator, A arg) {
5001 LocalVariableElement variable, 3294 return null;
5002 NodeList arguments, 3295 }
5003 CallStructure callStructure, 3296
5004 A arg) { 3297 @override
5005 apply(arguments, arg); 3298 R visitLocalVariablePrefix(Send node, LocalVariableElement variable,
5006 return null; 3299 IncDecOperator operator, A arg) {
5007 }
5008
5009 @override
5010 R visitLocalVariablePostfix(
5011 Send node,
5012 LocalVariableElement variable,
5013 IncDecOperator operator,
5014 A arg) {
5015 return null;
5016 }
5017
5018 @override
5019 R visitLocalVariablePrefix(
5020 Send node,
5021 LocalVariableElement variable,
5022 IncDecOperator operator,
5023 A arg) {
5024 return null; 3300 return null;
5025 } 3301 }
5026 3302
5027 @override 3303 @override
5028 R visitLocalVariableSet( 3304 R visitLocalVariableSet(
5029 SendSet node, 3305 SendSet node, LocalVariableElement variable, Node rhs, A arg) {
5030 LocalVariableElement variable, 3306 apply(rhs, arg);
5031 Node rhs, 3307 return null;
5032 A arg) { 3308 }
5033 apply(rhs, arg); 3309
5034 return null; 3310 @override
5035 } 3311 R visitIfNull(Send node, Node left, Node right, A arg) {
5036 3312 apply(left, arg);
5037 @override 3313 apply(right, arg);
5038 R visitIfNull( 3314 return null;
5039 Send node, 3315 }
5040 Node left, 3316
5041 Node right, 3317 @override
5042 A arg) { 3318 R visitLogicalAnd(Send node, Node left, Node right, A arg) {
5043 apply(left, arg); 3319 apply(left, arg);
5044 apply(right, arg); 3320 apply(right, arg);
5045 return null; 3321 return null;
5046 } 3322 }
5047 3323
5048 @override 3324 @override
5049 R visitLogicalAnd( 3325 R visitLogicalOr(Send node, Node left, Node right, A arg) {
5050 Send node, 3326 apply(left, arg);
5051 Node left, 3327 apply(right, arg);
5052 Node right, 3328 return null;
5053 A arg) { 3329 }
5054 apply(left, arg); 3330
5055 apply(right, arg); 3331 @override
5056 return null; 3332 R visitNot(Send node, Node expression, A arg) {
5057 }
5058
5059 @override
5060 R visitLogicalOr(
5061 Send node,
5062 Node left,
5063 Node right,
5064 A arg) {
5065 apply(left, arg);
5066 apply(right, arg);
5067 return null;
5068 }
5069
5070 @override
5071 R visitNot(
5072 Send node,
5073 Node expression,
5074 A arg) {
5075 apply(expression, arg); 3333 apply(expression, arg);
5076 return null; 3334 return null;
5077 } 3335 }
5078 3336
5079 @override 3337 @override
5080 R visitNotEquals( 3338 R visitNotEquals(Send node, Node left, Node right, A arg) {
5081 Send node, 3339 apply(left, arg);
5082 Node left, 3340 apply(right, arg);
5083 Node right, 3341 return null;
5084 A arg) { 3342 }
5085 apply(left, arg); 3343
5086 apply(right, arg); 3344 @override
5087 return null; 3345 R visitParameterCompound(Send node, ParameterElement parameter,
5088 } 3346 AssignmentOperator operator, Node rhs, A arg) {
5089 3347 apply(rhs, arg);
5090 @override 3348 return null;
5091 R visitParameterCompound( 3349 }
5092 Send node, 3350
5093 ParameterElement parameter, 3351 @override
5094 AssignmentOperator operator, 3352 R visitParameterGet(Send node, ParameterElement parameter, A arg) {
5095 Node rhs, 3353 return null;
5096 A arg) { 3354 }
5097 apply(rhs, arg); 3355
5098 return null; 3356 @override
5099 } 3357 R visitParameterInvoke(Send node, ParameterElement parameter,
5100 3358 NodeList arguments, CallStructure callStructure, A arg) {
5101 @override
5102 R visitParameterGet(
5103 Send node,
5104 ParameterElement parameter,
5105 A arg) {
5106 return null;
5107 }
5108
5109 @override
5110 R visitParameterInvoke(
5111 Send node,
5112 ParameterElement parameter,
5113 NodeList arguments,
5114 CallStructure callStructure,
5115 A arg) {
5116 apply(arguments, arg); 3359 apply(arguments, arg);
5117 return null; 3360 return null;
5118 } 3361 }
5119 3362
5120 @override 3363 @override
5121 R visitParameterPostfix( 3364 R visitParameterPostfix(
5122 Send node, 3365 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
5123 ParameterElement parameter,
5124 IncDecOperator operator,
5125 A arg) {
5126 return null; 3366 return null;
5127 } 3367 }
5128 3368
5129 @override 3369 @override
5130 R visitParameterPrefix( 3370 R visitParameterPrefix(
5131 Send node, 3371 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
5132 ParameterElement parameter,
5133 IncDecOperator operator,
5134 A arg) {
5135 return null; 3372 return null;
5136 } 3373 }
5137 3374
5138 @override 3375 @override
5139 R visitParameterSet( 3376 R visitParameterSet(
5140 SendSet node, 3377 SendSet node, ParameterElement parameter, Node rhs, A arg) {
5141 ParameterElement parameter, 3378 apply(rhs, arg);
5142 Node rhs, 3379 return null;
5143 A arg) { 3380 }
5144 apply(rhs, arg); 3381
5145 return null; 3382 @override
5146 } 3383 R visitStaticFieldCompound(Send node, FieldElement field,
5147 3384 AssignmentOperator operator, Node rhs, A arg) {
5148 @override 3385 apply(rhs, arg);
5149 R visitStaticFieldCompound( 3386 return null;
5150 Send node, 3387 }
5151 FieldElement field, 3388
5152 AssignmentOperator operator, 3389 @override
5153 Node rhs, 3390 R visitStaticFieldGet(Send node, FieldElement field, A arg) {
5154 A arg) { 3391 return null;
5155 apply(rhs, arg); 3392 }
5156 return null; 3393
5157 } 3394 @override
5158 3395 R visitStaticFieldInvoke(Send node, FieldElement field, NodeList arguments,
5159 @override 3396 CallStructure callStructure, A arg) {
5160 R visitStaticFieldGet(
5161 Send node,
5162 FieldElement field,
5163 A arg) {
5164 return null;
5165 }
5166
5167 @override
5168 R visitStaticFieldInvoke(
5169 Send node,
5170 FieldElement field,
5171 NodeList arguments,
5172 CallStructure callStructure,
5173 A arg) {
5174 apply(arguments, arg); 3397 apply(arguments, arg);
5175 return null; 3398 return null;
5176 } 3399 }
5177 3400
5178 @override 3401 @override
5179 R visitStaticFieldPostfix( 3402 R visitStaticFieldPostfix(
5180 Send node, 3403 Send node, FieldElement field, IncDecOperator operator, A arg) {
5181 FieldElement field,
5182 IncDecOperator operator,
5183 A arg) {
5184 return null; 3404 return null;
5185 } 3405 }
5186 3406
5187 @override 3407 @override
5188 R visitStaticFieldPrefix( 3408 R visitStaticFieldPrefix(
5189 Send node, 3409 Send node, FieldElement field, IncDecOperator operator, A arg) {
5190 FieldElement field, 3410 return null;
5191 IncDecOperator operator, 3411 }
5192 A arg) { 3412
5193 return null; 3413 @override
5194 } 3414 R visitStaticFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
5195 3415 apply(rhs, arg);
5196 @override 3416 return null;
5197 R visitStaticFieldSet( 3417 }
5198 SendSet node, 3418
5199 FieldElement field, 3419 @override
5200 Node rhs, 3420 R visitStaticFunctionGet(Send node, MethodElement function, A arg) {
5201 A arg) { 3421 return null;
5202 apply(rhs, arg); 3422 }
5203 return null; 3423
5204 } 3424 @override
5205 3425 R visitStaticFunctionInvoke(Send node, MethodElement function,
5206 @override 3426 NodeList arguments, CallStructure callStructure, A arg) {
5207 R visitStaticFunctionGet( 3427 apply(arguments, arg);
5208 Send node, 3428 return null;
5209 MethodElement function, 3429 }
5210 A arg) { 3430
5211 return null; 3431 @override
5212 } 3432 R visitStaticFunctionIncompatibleInvoke(Send node, MethodElement function,
5213 3433 NodeList arguments, CallStructure callStructure, A arg) {
5214 @override 3434 apply(arguments, arg);
5215 R visitStaticFunctionInvoke( 3435 return null;
5216 Send node, 3436 }
5217 MethodElement function, 3437
5218 NodeList arguments, 3438 @override
5219 CallStructure callStructure, 3439 R visitStaticGetterGet(Send node, FunctionElement getter, A arg) {
5220 A arg) { 3440 return null;
5221 apply(arguments, arg); 3441 }
5222 return null; 3442
5223 } 3443 @override
5224 3444 R visitStaticGetterInvoke(Send node, FunctionElement getter,
5225 @override 3445 NodeList arguments, CallStructure callStructure, A arg) {
5226 R visitStaticFunctionIncompatibleInvoke( 3446 apply(arguments, arg);
5227 Send node, 3447 return null;
5228 MethodElement function, 3448 }
5229 NodeList arguments, 3449
5230 CallStructure callStructure, 3450 @override
5231 A arg) { 3451 R visitStaticGetterSetterCompound(Send node, FunctionElement getter,
5232 apply(arguments, arg); 3452 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
5233 return null; 3453 apply(rhs, arg);
5234 } 3454 return null;
5235 3455 }
5236 @override 3456
5237 R visitStaticGetterGet( 3457 @override
5238 Send node, 3458 R visitStaticGetterSetterPostfix(Send node, FunctionElement getter,
5239 FunctionElement getter, 3459 FunctionElement setter, IncDecOperator operator, A arg) {
5240 A arg) { 3460 return null;
5241 return null; 3461 }
5242 } 3462
5243 3463 @override
5244 @override 3464 R visitStaticGetterSetterPrefix(Send node, FunctionElement getter,
5245 R visitStaticGetterInvoke( 3465 FunctionElement setter, IncDecOperator operator, A arg) {
5246 Send node, 3466 return null;
5247 FunctionElement getter, 3467 }
5248 NodeList arguments, 3468
5249 CallStructure callStructure, 3469 @override
5250 A arg) { 3470 R visitStaticMethodSetterCompound(Send node, FunctionElement method,
5251 apply(arguments, arg); 3471 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
5252 return null; 3472 apply(rhs, arg);
5253 } 3473 return null;
5254 3474 }
5255 @override 3475
5256 R visitStaticGetterSetterCompound( 3476 @override
5257 Send node, 3477 R visitStaticMethodSetterPostfix(Send node, FunctionElement getter,
5258 FunctionElement getter, 3478 FunctionElement setter, IncDecOperator operator, A arg) {
5259 FunctionElement setter, 3479 return null;
5260 AssignmentOperator operator, 3480 }
5261 Node rhs, 3481
5262 A arg) { 3482 @override
5263 apply(rhs, arg); 3483 R visitStaticMethodSetterPrefix(Send node, FunctionElement getter,
5264 return null; 3484 FunctionElement setter, IncDecOperator operator, A arg) {
5265 }
5266
5267 @override
5268 R visitStaticGetterSetterPostfix(
5269 Send node,
5270 FunctionElement getter,
5271 FunctionElement setter,
5272 IncDecOperator operator,
5273 A arg) {
5274 return null;
5275 }
5276
5277 @override
5278 R visitStaticGetterSetterPrefix(
5279 Send node,
5280 FunctionElement getter,
5281 FunctionElement setter,
5282 IncDecOperator operator,
5283 A arg) {
5284 return null;
5285 }
5286
5287 @override
5288 R visitStaticMethodSetterCompound(
5289 Send node,
5290 FunctionElement method,
5291 FunctionElement setter,
5292 AssignmentOperator operator,
5293 Node rhs,
5294 A arg) {
5295 apply(rhs, arg);
5296 return null;
5297 }
5298
5299 @override
5300 R visitStaticMethodSetterPostfix(
5301 Send node,
5302 FunctionElement getter,
5303 FunctionElement setter,
5304 IncDecOperator operator,
5305 A arg) {
5306 return null;
5307 }
5308
5309 @override
5310 R visitStaticMethodSetterPrefix(
5311 Send node,
5312 FunctionElement getter,
5313 FunctionElement setter,
5314 IncDecOperator operator,
5315 A arg) {
5316 return null; 3485 return null;
5317 } 3486 }
5318 3487
5319 @override 3488 @override
5320 R visitStaticSetterSet( 3489 R visitStaticSetterSet(
5321 SendSet node, 3490 SendSet node, FunctionElement setter, Node rhs, A arg) {
5322 FunctionElement setter, 3491 apply(rhs, arg);
5323 Node rhs, 3492 return null;
5324 A arg) { 3493 }
5325 apply(rhs, arg); 3494
5326 return null; 3495 @override
5327 } 3496 R visitSuperBinary(Send node, FunctionElement function,
5328 3497 BinaryOperator operator, Node argument, A arg) {
5329 @override
5330 R visitSuperBinary(
5331 Send node,
5332 FunctionElement function,
5333 BinaryOperator operator,
5334 Node argument,
5335 A arg) {
5336 apply(argument, arg); 3498 apply(argument, arg);
5337 return null; 3499 return null;
5338 } 3500 }
5339 3501
5340 @override 3502 @override
5341 R visitSuperCompoundIndexSet( 3503 R visitSuperCompoundIndexSet(
5342 SendSet node, 3504 SendSet node,
5343 FunctionElement getter, 3505 FunctionElement getter,
5344 FunctionElement setter, 3506 FunctionElement setter,
5345 Node index, 3507 Node index,
5346 AssignmentOperator operator, 3508 AssignmentOperator operator,
5347 Node rhs, 3509 Node rhs,
5348 A arg) { 3510 A arg) {
5349 apply(rhs, arg); 3511 apply(rhs, arg);
5350 return null; 3512 return null;
5351 } 3513 }
5352 3514
5353 @override 3515 @override
5354 R visitSuperEquals( 3516 R visitSuperEquals(
5355 Send node, 3517 Send node, FunctionElement function, Node argument, A arg) {
5356 FunctionElement function,
5357 Node argument,
5358 A arg) {
5359 apply(argument, arg); 3518 apply(argument, arg);
5360 return null; 3519 return null;
5361 } 3520 }
5362 3521
5363 @override 3522 @override
5364 R visitSuperFieldCompound( 3523 R visitSuperFieldCompound(Send node, FieldElement field,
5365 Send node, 3524 AssignmentOperator operator, Node rhs, A arg) {
5366 FieldElement field,
5367 AssignmentOperator operator,
5368 Node rhs,
5369 A arg) {
5370 apply(rhs, arg); 3525 apply(rhs, arg);
5371 return null; 3526 return null;
5372 } 3527 }
5373 3528
5374 @override 3529 @override
5375 R visitSuperFieldFieldPostfix( 3530 R visitSuperFieldFieldPostfix(Send node, FieldElement readField,
5376 Send node, 3531 FieldElement writtenField, IncDecOperator operator, A arg) {
5377 FieldElement readField,
5378 FieldElement writtenField,
5379 IncDecOperator operator,
5380 A arg) {
5381 return null; 3532 return null;
5382 } 3533 }
5383 3534
5384 @override 3535 @override
5385 R visitSuperFieldFieldPrefix( 3536 R visitSuperFieldFieldPrefix(Send node, FieldElement readField,
5386 Send node, 3537 FieldElement writtenField, IncDecOperator operator, A arg) {
5387 FieldElement readField,
5388 FieldElement writtenField,
5389 IncDecOperator operator,
5390 A arg) {
5391 return null; 3538 return null;
5392 } 3539 }
5393 3540
5394 @override 3541 @override
5395 R visitSuperFieldGet( 3542 R visitSuperFieldGet(Send node, FieldElement field, A arg) {
5396 Send node,
5397 FieldElement field,
5398 A arg) {
5399 return null; 3543 return null;
5400 } 3544 }
5401 3545
5402 @override 3546 @override
5403 R visitSuperFieldInvoke( 3547 R visitSuperFieldInvoke(Send node, FieldElement field, NodeList arguments,
5404 Send node, 3548 CallStructure callStructure, A arg) {
5405 FieldElement field,
5406 NodeList arguments,
5407 CallStructure callStructure,
5408 A arg) {
5409 apply(arguments, arg); 3549 apply(arguments, arg);
5410 return null; 3550 return null;
5411 } 3551 }
5412 3552
5413 @override 3553 @override
5414 R visitSuperFieldPostfix( 3554 R visitSuperFieldPostfix(
5415 Send node, 3555 Send node, FieldElement field, IncDecOperator operator, A arg) {
5416 FieldElement field,
5417 IncDecOperator operator,
5418 A arg) {
5419 return null; 3556 return null;
5420 } 3557 }
5421 3558
5422 @override 3559 @override
5423 R visitSuperFieldPrefix( 3560 R visitSuperFieldPrefix(
5424 Send node, 3561 Send node, FieldElement field, IncDecOperator operator, A arg) {
5425 FieldElement field,
5426 IncDecOperator operator,
5427 A arg) {
5428 return null; 3562 return null;
5429 } 3563 }
5430 3564
5431 @override 3565 @override
5432 R visitSuperFieldSet( 3566 R visitSuperFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
5433 SendSet node,
5434 FieldElement field,
5435 Node rhs,
5436 A arg) {
5437 apply(rhs, arg); 3567 apply(rhs, arg);
5438 return null; 3568 return null;
5439 } 3569 }
5440 3570
5441 @override 3571 @override
5442 R visitSuperFieldSetterCompound( 3572 R visitSuperFieldSetterCompound(Send node, FieldElement field,
5443 Send node, 3573 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
5444 FieldElement field,
5445 FunctionElement setter,
5446 AssignmentOperator operator,
5447 Node rhs,
5448 A arg) {
5449 apply(rhs, arg); 3574 apply(rhs, arg);
5450 return null; 3575 return null;
5451 } 3576 }
5452 3577
5453 @override 3578 @override
5454 R visitSuperFieldSetterPostfix( 3579 R visitSuperFieldSetterPostfix(Send node, FieldElement field,
5455 Send node, 3580 FunctionElement setter, IncDecOperator operator, A arg) {
5456 FieldElement field,
5457 FunctionElement setter,
5458 IncDecOperator operator,
5459 A arg) {
5460 return null; 3581 return null;
5461 } 3582 }
5462 3583
5463 @override 3584 @override
5464 R visitSuperFieldSetterPrefix( 3585 R visitSuperFieldSetterPrefix(Send node, FieldElement field,
5465 Send node, 3586 FunctionElement setter, IncDecOperator operator, A arg) {
5466 FieldElement field,
5467 FunctionElement setter,
5468 IncDecOperator operator,
5469 A arg) {
5470 return null; 3587 return null;
5471 } 3588 }
5472 3589
5473 @override 3590 @override
5474 R visitSuperGetterFieldCompound( 3591 R visitSuperGetterFieldCompound(Send node, FunctionElement getter,
5475 Send node, 3592 FieldElement field, AssignmentOperator operator, Node rhs, A arg) {
5476 FunctionElement getter,
5477 FieldElement field,
5478 AssignmentOperator operator,
5479 Node rhs,
5480 A arg) {
5481 apply(rhs, arg); 3593 apply(rhs, arg);
5482 return null; 3594 return null;
5483 } 3595 }
5484 3596
5485 @override 3597 @override
5486 R visitSuperGetterFieldPostfix( 3598 R visitSuperGetterFieldPostfix(Send node, FunctionElement getter,
5487 Send node, 3599 FieldElement field, IncDecOperator operator, A arg) {
5488 FunctionElement getter,
5489 FieldElement field,
5490 IncDecOperator operator,
5491 A arg) {
5492 return null; 3600 return null;
5493 } 3601 }
5494 3602
5495 @override 3603 @override
5496 R visitSuperGetterFieldPrefix( 3604 R visitSuperGetterFieldPrefix(Send node, FunctionElement getter,
5497 Send node, 3605 FieldElement field, IncDecOperator operator, A arg) {
5498 FunctionElement getter,
5499 FieldElement field,
5500 IncDecOperator operator,
5501 A arg) {
5502 return null; 3606 return null;
5503 } 3607 }
5504 3608
5505 @override 3609 @override
5506 R visitSuperGetterGet( 3610 R visitSuperGetterGet(Send node, FunctionElement getter, A arg) {
5507 Send node,
5508 FunctionElement getter,
5509 A arg) {
5510 return null; 3611 return null;
5511 } 3612 }
5512 3613
5513 @override 3614 @override
5514 R visitSuperGetterInvoke( 3615 R visitSuperGetterInvoke(Send node, FunctionElement getter,
5515 Send node, 3616 NodeList arguments, CallStructure callStructure, A arg) {
5516 FunctionElement getter,
5517 NodeList arguments,
5518 CallStructure callStructure,
5519 A arg) {
5520 apply(arguments, arg); 3617 apply(arguments, arg);
5521 return null; 3618 return null;
5522 } 3619 }
5523 3620
5524 @override 3621 @override
5525 R visitSuperGetterSetterCompound( 3622 R visitSuperGetterSetterCompound(Send node, FunctionElement getter,
5526 Send node, 3623 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
5527 FunctionElement getter,
5528 FunctionElement setter,
5529 AssignmentOperator operator,
5530 Node rhs,
5531 A arg) {
5532 apply(rhs, arg); 3624 apply(rhs, arg);
5533 return null; 3625 return null;
5534 } 3626 }
5535 3627
5536 @override 3628 @override
5537 R visitSuperGetterSetterPostfix( 3629 R visitSuperGetterSetterPostfix(Send node, FunctionElement getter,
5538 Send node, 3630 FunctionElement setter, IncDecOperator operator, A arg) {
5539 FunctionElement getter,
5540 FunctionElement setter,
5541 IncDecOperator operator,
5542 A arg) {
5543 return null; 3631 return null;
5544 } 3632 }
5545 3633
5546 @override 3634 @override
5547 R visitSuperGetterSetterPrefix( 3635 R visitSuperGetterSetterPrefix(Send node, FunctionElement getter,
5548 Send node, 3636 FunctionElement setter, IncDecOperator operator, A arg) {
5549 FunctionElement getter,
5550 FunctionElement setter,
5551 IncDecOperator operator,
5552 A arg) {
5553 return null; 3637 return null;
5554 } 3638 }
5555 3639
5556 @override 3640 @override
5557 R visitSuperIndex( 3641 R visitSuperIndex(Send node, FunctionElement function, Node index, A arg) {
5558 Send node,
5559 FunctionElement function,
5560 Node index,
5561 A arg) {
5562 apply(index, arg); 3642 apply(index, arg);
5563 return null; 3643 return null;
5564 } 3644 }
5565 3645
5566 @override 3646 @override
5567 R visitSuperIndexSet( 3647 R visitSuperIndexSet(
5568 SendSet node, 3648 SendSet node, FunctionElement function, Node index, Node rhs, A arg) {
5569 FunctionElement function,
5570 Node index,
5571 Node rhs,
5572 A arg) {
5573 apply(index, arg); 3649 apply(index, arg);
5574 apply(rhs, arg); 3650 apply(rhs, arg);
5575 return null; 3651 return null;
5576 } 3652 }
5577 3653
5578 @override 3654 @override
5579 R visitSuperMethodGet( 3655 R visitSuperMethodGet(Send node, MethodElement method, A arg) {
5580 Send node,
5581 MethodElement method,
5582 A arg) {
5583 return null; 3656 return null;
5584 } 3657 }
5585 3658
5586 @override 3659 @override
5587 R visitSuperMethodInvoke( 3660 R visitSuperMethodInvoke(Send node, MethodElement method, NodeList arguments,
5588 Send node, 3661 CallStructure callStructure, A arg) {
5589 MethodElement method,
5590 NodeList arguments,
5591 CallStructure callStructure,
5592 A arg) {
5593 apply(arguments, arg); 3662 apply(arguments, arg);
5594 return null; 3663 return null;
5595 } 3664 }
5596 3665
5597 @override 3666 @override
5598 R visitSuperMethodIncompatibleInvoke( 3667 R visitSuperMethodIncompatibleInvoke(Send node, MethodElement method,
5599 Send node, 3668 NodeList arguments, CallStructure callStructure, A arg) {
5600 MethodElement method,
5601 NodeList arguments,
5602 CallStructure callStructure,
5603 A arg) {
5604 apply(arguments, arg); 3669 apply(arguments, arg);
5605 return null; 3670 return null;
5606 } 3671 }
5607 3672
5608 @override 3673 @override
5609 R visitSuperMethodSetterCompound( 3674 R visitSuperMethodSetterCompound(Send node, FunctionElement method,
5610 Send node, 3675 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
5611 FunctionElement method,
5612 FunctionElement setter,
5613 AssignmentOperator operator,
5614 Node rhs,
5615 A arg) {
5616 apply(rhs, arg); 3676 apply(rhs, arg);
5617 return null; 3677 return null;
5618 } 3678 }
5619 3679
5620 @override 3680 @override
5621 R visitSuperMethodSetterPostfix( 3681 R visitSuperMethodSetterPostfix(Send node, FunctionElement method,
5622 Send node, 3682 FunctionElement setter, IncDecOperator operator, A arg) {
5623 FunctionElement method,
5624 FunctionElement setter,
5625 IncDecOperator operator,
5626 A arg) {
5627 return null; 3683 return null;
5628 } 3684 }
5629 3685
5630 @override 3686 @override
5631 R visitSuperMethodSetterPrefix( 3687 R visitSuperMethodSetterPrefix(Send node, FunctionElement method,
5632 Send node, 3688 FunctionElement setter, IncDecOperator operator, A arg) {
5633 FunctionElement method,
5634 FunctionElement setter,
5635 IncDecOperator operator,
5636 A arg) {
5637 return null; 3689 return null;
5638 } 3690 }
5639 3691
5640 @override 3692 @override
5641 R visitSuperNotEquals( 3693 R visitSuperNotEquals(
5642 Send node, 3694 Send node, FunctionElement function, Node argument, A arg) {
5643 FunctionElement function,
5644 Node argument,
5645 A arg) {
5646 apply(argument, arg); 3695 apply(argument, arg);
5647 return null; 3696 return null;
5648 } 3697 }
5649 3698
5650 @override 3699 @override
5651 R visitSuperSetterSet( 3700 R visitSuperSetterSet(SendSet node, FunctionElement setter, Node rhs, A arg) {
5652 SendSet node,
5653 FunctionElement setter,
5654 Node rhs,
5655 A arg) {
5656 apply(rhs, arg); 3701 apply(rhs, arg);
5657 return null; 3702 return null;
5658 } 3703 }
5659 3704
5660 @override 3705 @override
5661 R visitSuperUnary( 3706 R visitSuperUnary(
5662 Send node, 3707 Send node, UnaryOperator operator, FunctionElement function, A arg) {
5663 UnaryOperator operator,
5664 FunctionElement function,
5665 A arg) {
5666 return null; 3708 return null;
5667 } 3709 }
5668 3710
5669 @override 3711 @override
5670 R visitThisGet(Identifier node, A arg) { 3712 R visitThisGet(Identifier node, A arg) {
5671 return null; 3713 return null;
5672 } 3714 }
5673 3715
5674 @override 3716 @override
5675 R visitThisInvoke( 3717 R visitThisInvoke(
5676 Send node, 3718 Send node, NodeList arguments, CallStructure callStructure, A arg) {
5677 NodeList arguments,
5678 CallStructure callStructure,
5679 A arg) {
5680 apply(arguments, arg); 3719 apply(arguments, arg);
5681 return null; 3720 return null;
5682 } 3721 }
5683 3722
5684 @override 3723 @override
5685 R visitThisPropertyCompound( 3724 R visitThisPropertyCompound(
5686 Send node, 3725 Send node, Name name, AssignmentOperator operator, Node rhs, A arg) {
5687 Name name, 3726 apply(rhs, arg);
5688 AssignmentOperator operator, 3727 return null;
5689 Node rhs, 3728 }
5690 A arg) { 3729
5691 apply(rhs, arg); 3730 @override
5692 return null; 3731 R visitThisPropertyGet(Send node, Name name, A arg) {
5693 }
5694
5695 @override
5696 R visitThisPropertyGet(
5697 Send node,
5698 Name name,
5699 A arg) {
5700 return null; 3732 return null;
5701 } 3733 }
5702 3734
5703 @override 3735 @override
5704 R visitThisPropertyInvoke( 3736 R visitThisPropertyInvoke(
5705 Send node, 3737 Send node, NodeList arguments, Selector selector, A arg) {
5706 NodeList arguments,
5707 Selector selector,
5708 A arg) {
5709 apply(arguments, arg); 3738 apply(arguments, arg);
5710 return null; 3739 return null;
5711 } 3740 }
5712 3741
5713 @override 3742 @override
5714 R visitThisPropertyPostfix( 3743 R visitThisPropertyPostfix(
5715 Send node, 3744 Send node, Name name, IncDecOperator operator, A arg) {
5716 Name name,
5717 IncDecOperator operator,
5718 A arg) {
5719 return null; 3745 return null;
5720 } 3746 }
5721 3747
5722 @override 3748 @override
5723 R visitThisPropertyPrefix( 3749 R visitThisPropertyPrefix(
5724 Send node, 3750 Send node, Name name, IncDecOperator operator, A arg) {
5725 Name name, 3751 return null;
5726 IncDecOperator operator, 3752 }
5727 A arg) { 3753
5728 return null; 3754 @override
5729 } 3755 R visitThisPropertySet(SendSet node, Name name, Node rhs, A arg) {
5730 3756 apply(rhs, arg);
5731 @override 3757 return null;
5732 R visitThisPropertySet( 3758 }
5733 SendSet node, 3759
5734 Name name, 3760 @override
5735 Node rhs, 3761 R visitTopLevelFieldCompound(Send node, FieldElement field,
5736 A arg) { 3762 AssignmentOperator operator, Node rhs, A arg) {
5737 apply(rhs, arg); 3763 apply(rhs, arg);
5738 return null; 3764 return null;
5739 } 3765 }
5740 3766
5741 @override 3767 @override
5742 R visitTopLevelFieldCompound( 3768 R visitTopLevelFieldGet(Send node, FieldElement field, A arg) {
5743 Send node, 3769 return null;
5744 FieldElement field, 3770 }
5745 AssignmentOperator operator, 3771
5746 Node rhs, 3772 @override
5747 A arg) { 3773 R visitTopLevelFieldInvoke(Send node, FieldElement field, NodeList arguments,
5748 apply(rhs, arg); 3774 CallStructure callStructure, A arg) {
5749 return null;
5750 }
5751
5752 @override
5753 R visitTopLevelFieldGet(
5754 Send node,
5755 FieldElement field,
5756 A arg) {
5757 return null;
5758 }
5759
5760 @override
5761 R visitTopLevelFieldInvoke(
5762 Send node,
5763 FieldElement field,
5764 NodeList arguments,
5765 CallStructure callStructure,
5766 A arg) {
5767 apply(arguments, arg); 3775 apply(arguments, arg);
5768 return null; 3776 return null;
5769 } 3777 }
5770 3778
5771 @override 3779 @override
5772 R visitTopLevelFieldPostfix( 3780 R visitTopLevelFieldPostfix(
5773 Send node, 3781 Send node, FieldElement field, IncDecOperator operator, A arg) {
5774 FieldElement field,
5775 IncDecOperator operator,
5776 A arg) {
5777 return null; 3782 return null;
5778 } 3783 }
5779 3784
5780 @override 3785 @override
5781 R visitTopLevelFieldPrefix( 3786 R visitTopLevelFieldPrefix(
5782 Send node, 3787 Send node, FieldElement field, IncDecOperator operator, A arg) {
5783 FieldElement field, 3788 return null;
5784 IncDecOperator operator, 3789 }
5785 A arg) { 3790
5786 return null; 3791 @override
5787 } 3792 R visitTopLevelFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
5788 3793 apply(rhs, arg);
5789 @override 3794 return null;
5790 R visitTopLevelFieldSet( 3795 }
5791 SendSet node, 3796
5792 FieldElement field, 3797 @override
5793 Node rhs, 3798 R visitTopLevelFunctionGet(Send node, MethodElement function, A arg) {
5794 A arg) { 3799 return null;
5795 apply(rhs, arg); 3800 }
5796 return null; 3801
5797 } 3802 @override
5798 3803 R visitTopLevelFunctionInvoke(Send node, MethodElement function,
5799 @override 3804 NodeList arguments, CallStructure callStructure, A arg) {
5800 R visitTopLevelFunctionGet( 3805 apply(arguments, arg);
5801 Send node, 3806 return null;
5802 MethodElement function, 3807 }
5803 A arg) { 3808
5804 return null; 3809 @override
5805 } 3810 R visitTopLevelFunctionIncompatibleInvoke(Send node, MethodElement function,
5806 3811 NodeList arguments, CallStructure callStructure, A arg) {
5807 @override 3812 apply(arguments, arg);
5808 R visitTopLevelFunctionInvoke( 3813 return null;
5809 Send node, 3814 }
5810 MethodElement function, 3815
5811 NodeList arguments, 3816 @override
5812 CallStructure callStructure, 3817 R visitTopLevelGetterGet(Send node, FunctionElement getter, A arg) {
5813 A arg) { 3818 return null;
5814 apply(arguments, arg); 3819 }
5815 return null; 3820
5816 } 3821 @override
5817 3822 R visitTopLevelGetterInvoke(Send node, FunctionElement getter,
5818 @override 3823 NodeList arguments, CallStructure callStructure, A arg) {
5819 R visitTopLevelFunctionIncompatibleInvoke( 3824 apply(arguments, arg);
5820 Send node, 3825 return null;
5821 MethodElement function, 3826 }
5822 NodeList arguments, 3827
5823 CallStructure callStructure, 3828 @override
5824 A arg) { 3829 R visitTopLevelGetterSetterCompound(Send node, FunctionElement getter,
5825 apply(arguments, arg); 3830 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
5826 return null; 3831 apply(rhs, arg);
5827 } 3832 return null;
5828 3833 }
5829 @override 3834
5830 R visitTopLevelGetterGet( 3835 @override
5831 Send node, 3836 R visitTopLevelGetterSetterPostfix(Send node, FunctionElement getter,
5832 FunctionElement getter, 3837 FunctionElement setter, IncDecOperator operator, A arg) {
5833 A arg) { 3838 return null;
5834 return null; 3839 }
5835 } 3840
5836 3841 @override
5837 @override 3842 R visitTopLevelGetterSetterPrefix(Send node, FunctionElement getter,
5838 R visitTopLevelGetterInvoke( 3843 FunctionElement setter, IncDecOperator operator, A arg) {
5839 Send node, 3844 return null;
5840 FunctionElement getter, 3845 }
5841 NodeList arguments, 3846
5842 CallStructure callStructure, 3847 @override
5843 A arg) { 3848 R visitTopLevelMethodSetterCompound(Send node, FunctionElement method,
5844 apply(arguments, arg); 3849 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
5845 return null; 3850 apply(rhs, arg);
5846 } 3851 return null;
5847 3852 }
5848 @override 3853
5849 R visitTopLevelGetterSetterCompound( 3854 @override
5850 Send node, 3855 R visitTopLevelMethodSetterPostfix(Send node, FunctionElement method,
5851 FunctionElement getter, 3856 FunctionElement setter, IncDecOperator operator, A arg) {
5852 FunctionElement setter, 3857 return null;
5853 AssignmentOperator operator, 3858 }
5854 Node rhs, 3859
5855 A arg) { 3860 @override
5856 apply(rhs, arg); 3861 R visitTopLevelMethodSetterPrefix(Send node, FunctionElement method,
5857 return null; 3862 FunctionElement setter, IncDecOperator operator, A arg) {
5858 }
5859
5860 @override
5861 R visitTopLevelGetterSetterPostfix(
5862 Send node,
5863 FunctionElement getter,
5864 FunctionElement setter,
5865 IncDecOperator operator,
5866 A arg) {
5867 return null;
5868 }
5869
5870 @override
5871 R visitTopLevelGetterSetterPrefix(
5872 Send node,
5873 FunctionElement getter,
5874 FunctionElement setter,
5875 IncDecOperator operator,
5876 A arg) {
5877 return null;
5878 }
5879
5880 @override
5881 R visitTopLevelMethodSetterCompound(
5882 Send node,
5883 FunctionElement method,
5884 FunctionElement setter,
5885 AssignmentOperator operator,
5886 Node rhs,
5887 A arg) {
5888 apply(rhs, arg);
5889 return null;
5890 }
5891
5892 @override
5893 R visitTopLevelMethodSetterPostfix(
5894 Send node,
5895 FunctionElement method,
5896 FunctionElement setter,
5897 IncDecOperator operator,
5898 A arg) {
5899 return null;
5900 }
5901
5902 @override
5903 R visitTopLevelMethodSetterPrefix(
5904 Send node,
5905 FunctionElement method,
5906 FunctionElement setter,
5907 IncDecOperator operator,
5908 A arg) {
5909 return null; 3863 return null;
5910 } 3864 }
5911 3865
5912 @override 3866 @override
5913 R visitTopLevelSetterSet( 3867 R visitTopLevelSetterSet(
5914 SendSet node, 3868 SendSet node, FunctionElement setter, Node rhs, A arg) {
5915 FunctionElement setter, 3869 apply(rhs, arg);
5916 Node rhs, 3870 return null;
5917 A arg) { 3871 }
5918 apply(rhs, arg); 3872
5919 return null; 3873 @override
5920 } 3874 R visitTypeVariableTypeLiteralCompound(Send node, TypeVariableElement element,
5921 3875 AssignmentOperator operator, Node rhs, A arg) {
5922 @override
5923 R visitTypeVariableTypeLiteralCompound(
5924 Send node,
5925 TypeVariableElement element,
5926 AssignmentOperator operator,
5927 Node rhs,
5928 A arg) {
5929 apply(rhs, arg); 3876 apply(rhs, arg);
5930 return null; 3877 return null;
5931 } 3878 }
5932 3879
5933 @override 3880 @override
5934 R visitTypeVariableTypeLiteralGet( 3881 R visitTypeVariableTypeLiteralGet(
5935 Send node, 3882 Send node, TypeVariableElement element, A arg) {
5936 TypeVariableElement element, 3883 return null;
5937 A arg) { 3884 }
5938 return null; 3885
5939 } 3886 @override
5940 3887 R visitTypeVariableTypeLiteralInvoke(Send node, TypeVariableElement element,
5941 @override 3888 NodeList arguments, CallStructure callStructure, A arg) {
5942 R visitTypeVariableTypeLiteralInvoke(
5943 Send node,
5944 TypeVariableElement element,
5945 NodeList arguments,
5946 CallStructure callStructure,
5947 A arg) {
5948 apply(arguments, arg); 3889 apply(arguments, arg);
5949 return null; 3890 return null;
5950 } 3891 }
5951 3892
5952 @override 3893 @override
5953 R visitTypeVariableTypeLiteralPostfix( 3894 R visitTypeVariableTypeLiteralPostfix(
5954 Send node, 3895 Send node, TypeVariableElement element, IncDecOperator operator, A arg) {
5955 TypeVariableElement element,
5956 IncDecOperator operator,
5957 A arg) {
5958 return null; 3896 return null;
5959 } 3897 }
5960 3898
5961 @override 3899 @override
5962 R visitTypeVariableTypeLiteralPrefix( 3900 R visitTypeVariableTypeLiteralPrefix(
5963 Send node, 3901 Send node, TypeVariableElement element, IncDecOperator operator, A arg) {
5964 TypeVariableElement element, 3902 return null;
5965 IncDecOperator operator, 3903 }
5966 A arg) { 3904
5967 return null; 3905 @override
5968 } 3906 R visitTypedefTypeLiteralCompound(Send node, ConstantExpression constant,
5969 3907 AssignmentOperator operator, Node rhs, A arg) {
5970 @override 3908 apply(rhs, arg);
5971 R visitTypedefTypeLiteralCompound( 3909 return null;
5972 Send node, 3910 }
5973 ConstantExpression constant, 3911
5974 AssignmentOperator operator, 3912 @override
5975 Node rhs, 3913 R visitTypedefTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
5976 A arg) { 3914 return null;
5977 apply(rhs, arg); 3915 }
5978 return null; 3916
5979 } 3917 @override
5980 3918 R visitTypedefTypeLiteralInvoke(Send node, ConstantExpression constant,
5981 @override 3919 NodeList arguments, CallStructure callStructure, A arg) {
5982 R visitTypedefTypeLiteralGet(
5983 Send node,
5984 ConstantExpression constant,
5985 A arg) {
5986 return null;
5987 }
5988
5989 @override
5990 R visitTypedefTypeLiteralInvoke(
5991 Send node,
5992 ConstantExpression constant,
5993 NodeList arguments,
5994 CallStructure callStructure,
5995 A arg) {
5996 apply(arguments, arg); 3920 apply(arguments, arg);
5997 return null; 3921 return null;
5998 } 3922 }
5999 3923
6000 @override 3924 @override
6001 R visitTypedefTypeLiteralPostfix( 3925 R visitTypedefTypeLiteralPostfix(
6002 Send node, 3926 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
6003 ConstantExpression constant,
6004 IncDecOperator operator,
6005 A arg) {
6006 return null; 3927 return null;
6007 } 3928 }
6008 3929
6009 @override 3930 @override
6010 R visitTypedefTypeLiteralPrefix( 3931 R visitTypedefTypeLiteralPrefix(
6011 Send node, 3932 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
6012 ConstantExpression constant, 3933 return null;
6013 IncDecOperator operator, 3934 }
6014 A arg) { 3935
6015 return null; 3936 @override
6016 } 3937 R visitUnary(Send node, UnaryOperator operator, Node expression, A arg) {
6017
6018 @override
6019 R visitUnary(
6020 Send node,
6021 UnaryOperator operator,
6022 Node expression,
6023 A arg) {
6024 apply(expression, arg); 3938 apply(expression, arg);
6025 return null; 3939 return null;
6026 } 3940 }
6027 3941
6028 @override 3942 @override
6029 R visitUnresolvedCompound( 3943 R visitUnresolvedCompound(Send node, Element element,
6030 Send node, 3944 AssignmentOperator operator, Node rhs, A arg) {
6031 Element element, 3945 apply(rhs, arg);
6032 AssignmentOperator operator, 3946 return null;
6033 Node rhs, 3947 }
6034 A arg) { 3948
6035 apply(rhs, arg); 3949 @override
6036 return null; 3950 R visitUnresolvedGet(Send node, Element element, A arg) {
6037 } 3951 return null;
6038 3952 }
6039 @override 3953
6040 R visitUnresolvedGet( 3954 @override
6041 Send node, 3955 R visitUnresolvedInvoke(Send node, Element element, NodeList arguments,
6042 Element element, 3956 Selector selector, A arg) {
6043 A arg) {
6044 return null;
6045 }
6046
6047 @override
6048 R visitUnresolvedInvoke(
6049 Send node,
6050 Element element,
6051 NodeList arguments,
6052 Selector selector,
6053 A arg) {
6054 apply(arguments, arg); 3957 apply(arguments, arg);
6055 return null; 3958 return null;
6056 } 3959 }
6057 3960
6058 @override 3961 @override
6059 R visitUnresolvedPostfix( 3962 R visitUnresolvedPostfix(
6060 Send node, 3963 Send node, Element element, IncDecOperator operator, A arg) {
6061 Element element,
6062 IncDecOperator operator,
6063 A arg) {
6064 return null; 3964 return null;
6065 } 3965 }
6066 3966
6067 @override 3967 @override
6068 R visitUnresolvedPrefix( 3968 R visitUnresolvedPrefix(
6069 Send node, 3969 Send node, Element element, IncDecOperator operator, A arg) {
6070 Element element, 3970 return null;
6071 IncDecOperator operator, 3971 }
6072 A arg) { 3972
6073 return null; 3973 @override
6074 } 3974 R visitUnresolvedSet(Send node, Element element, Node rhs, A arg) {
6075
6076 @override
6077 R visitUnresolvedSet(
6078 Send node,
6079 Element element,
6080 Node rhs,
6081 A arg) {
6082 apply(rhs, arg); 3975 apply(rhs, arg);
6083 return null; 3976 return null;
6084 } 3977 }
6085 3978
6086 @override 3979 @override
6087 R errorUndefinedBinaryExpression( 3980 R errorUndefinedBinaryExpression(
6088 Send node, 3981 Send node, Node left, Operator operator, Node right, A arg) {
6089 Node left,
6090 Operator operator,
6091 Node right,
6092 A arg) {
6093 apply(left, arg); 3982 apply(left, arg);
6094 apply(right, arg); 3983 apply(right, arg);
6095 return null; 3984 return null;
6096 } 3985 }
6097 3986
6098 @override 3987 @override
6099 R errorUndefinedUnaryExpression( 3988 R errorUndefinedUnaryExpression(
6100 Send node, 3989 Send node, Operator operator, Node expression, A arg) {
6101 Operator operator,
6102 Node expression,
6103 A arg) {
6104 apply(expression, arg); 3990 apply(expression, arg);
6105 return null; 3991 return null;
6106 } 3992 }
6107 3993
6108 @override 3994 @override
6109 R visitUnresolvedSuperIndexSet( 3995 R visitUnresolvedSuperIndexSet(
6110 Send node, 3996 Send node, Element element, Node index, Node rhs, A arg) {
6111 Element element,
6112 Node index,
6113 Node rhs,
6114 A arg) {
6115 apply(index, arg); 3997 apply(index, arg);
6116 apply(rhs, arg); 3998 apply(rhs, arg);
6117 return null; 3999 return null;
6118 } 4000 }
6119 4001
6120 @override 4002 @override
6121 R visitUnresolvedSuperGetterCompoundIndexSet( 4003 R visitUnresolvedSuperGetterCompoundIndexSet(
6122 SendSet node, 4004 SendSet node,
6123 Element element, 4005 Element element,
6124 MethodElement setter, 4006 MethodElement setter,
(...skipping 14 matching lines...) Expand all
6139 Node index, 4021 Node index,
6140 AssignmentOperator operator, 4022 AssignmentOperator operator,
6141 Node rhs, 4023 Node rhs,
6142 A arg) { 4024 A arg) {
6143 apply(index, arg); 4025 apply(index, arg);
6144 apply(rhs, arg); 4026 apply(rhs, arg);
6145 return null; 4027 return null;
6146 } 4028 }
6147 4029
6148 @override 4030 @override
6149 R visitUnresolvedSuperCompoundIndexSet( 4031 R visitUnresolvedSuperCompoundIndexSet(SendSet node, Element element,
6150 SendSet node, 4032 Node index, AssignmentOperator operator, Node rhs, A arg) {
6151 Element element,
6152 Node index,
6153 AssignmentOperator operator,
6154 Node rhs,
6155 A arg) {
6156 apply(index, arg); 4033 apply(index, arg);
6157 apply(rhs, arg); 4034 apply(rhs, arg);
6158 return null; 4035 return null;
6159 } 4036 }
6160 4037
6161 @override 4038 @override
6162 R visitUnresolvedSuperBinary( 4039 R visitUnresolvedSuperBinary(Send node, Element element,
6163 Send node, 4040 BinaryOperator operator, Node argument, A arg) {
6164 Element element,
6165 BinaryOperator operator,
6166 Node argument,
6167 A arg) {
6168 apply(argument, arg); 4041 apply(argument, arg);
6169 return null; 4042 return null;
6170 } 4043 }
6171 4044
6172 @override 4045 @override
6173 R visitUnresolvedSuperUnary( 4046 R visitUnresolvedSuperUnary(
6174 Send node, 4047 Send node, UnaryOperator operator, Element element, A arg) {
6175 UnaryOperator operator,
6176 Element element,
6177 A arg) {
6178 return null; 4048 return null;
6179 } 4049 }
6180 4050
6181 @override 4051 @override
6182 R visitUnresolvedSuperGetterIndexPostfix( 4052 R visitUnresolvedSuperGetterIndexPostfix(Send node, Element element,
6183 Send node, 4053 MethodElement setter, Node index, IncDecOperator operator, A arg) {
6184 Element element,
6185 MethodElement setter,
6186 Node index,
6187 IncDecOperator operator,
6188 A arg) {
6189 apply(index, arg); 4054 apply(index, arg);
6190 return null; 4055 return null;
6191 } 4056 }
6192 4057
6193 @override 4058 @override
6194 R visitUnresolvedSuperSetterIndexPostfix( 4059 R visitUnresolvedSuperSetterIndexPostfix(Send node, MethodElement getter,
6195 Send node, 4060 Element element, Node index, IncDecOperator operator, A arg) {
6196 MethodElement getter,
6197 Element element,
6198 Node index,
6199 IncDecOperator operator,
6200 A arg) {
6201 apply(index, arg); 4061 apply(index, arg);
6202 return null; 4062 return null;
6203 } 4063 }
6204 4064
6205 @override 4065 @override
6206 R visitUnresolvedSuperIndexPostfix( 4066 R visitUnresolvedSuperIndexPostfix(
6207 Send node, 4067 Send node, Element element, Node index, IncDecOperator operator, A arg) {
6208 Element element,
6209 Node index,
6210 IncDecOperator operator,
6211 A arg) {
6212 apply(index, arg); 4068 apply(index, arg);
6213 return null; 4069 return null;
6214 } 4070 }
6215 4071
6216 @override 4072 @override
6217 R visitUnresolvedSuperGetterIndexPrefix( 4073 R visitUnresolvedSuperGetterIndexPrefix(Send node, Element element,
6218 Send node, 4074 MethodElement setter, Node index, IncDecOperator operator, A arg) {
6219 Element element,
6220 MethodElement setter,
6221 Node index,
6222 IncDecOperator operator,
6223 A arg) {
6224 apply(index, arg); 4075 apply(index, arg);
6225 return null; 4076 return null;
6226 } 4077 }
6227 4078
6228 @override 4079 @override
6229 R visitUnresolvedSuperSetterIndexPrefix( 4080 R visitUnresolvedSuperSetterIndexPrefix(Send node, MethodElement getter,
6230 Send node, 4081 Element element, Node index, IncDecOperator operator, A arg) {
6231 MethodElement getter,
6232 Element element,
6233 Node index,
6234 IncDecOperator operator,
6235 A arg) {
6236 apply(index, arg); 4082 apply(index, arg);
6237 return null; 4083 return null;
6238 } 4084 }
6239 4085
6240 @override 4086 @override
6241 R visitUnresolvedSuperIndexPrefix( 4087 R visitUnresolvedSuperIndexPrefix(
6242 Send node, 4088 Send node, Element element, Node index, IncDecOperator operator, A arg) {
6243 Element element,
6244 Node index,
6245 IncDecOperator operator,
6246 A arg) {
6247 apply(index, arg); 4089 apply(index, arg);
6248 return null; 4090 return null;
6249 } 4091 }
6250 4092
6251 @override 4093 @override
6252 R visitIndexPostfix( 4094 R visitIndexPostfix(
6253 Send node, 4095 Send node, Node receiver, Node index, IncDecOperator operator, A arg) {
6254 Node receiver,
6255 Node index,
6256 IncDecOperator operator,
6257 A arg) {
6258 apply(receiver, arg); 4096 apply(receiver, arg);
6259 apply(index, arg); 4097 apply(index, arg);
6260 return null; 4098 return null;
6261 } 4099 }
6262 4100
6263 @override 4101 @override
6264 R visitIndexPrefix( 4102 R visitIndexPrefix(
6265 Send node, 4103 Send node, Node receiver, Node index, IncDecOperator operator, A arg) {
6266 Node receiver,
6267 Node index,
6268 IncDecOperator operator,
6269 A arg) {
6270 apply(receiver, arg); 4104 apply(receiver, arg);
6271 apply(index, arg); 4105 apply(index, arg);
6272 return null; 4106 return null;
6273 } 4107 }
6274 4108
6275 @override 4109 @override
6276 R visitSuperIndexPostfix( 4110 R visitSuperIndexPostfix(
6277 Send node, 4111 Send node,
6278 FunctionElement indexFunction, 4112 FunctionElement indexFunction,
6279 FunctionElement indexSetFunction, 4113 FunctionElement indexSetFunction,
(...skipping 10 matching lines...) Expand all
6290 FunctionElement indexFunction, 4124 FunctionElement indexFunction,
6291 FunctionElement indexSetFunction, 4125 FunctionElement indexSetFunction,
6292 Node index, 4126 Node index,
6293 IncDecOperator operator, 4127 IncDecOperator operator,
6294 A arg) { 4128 A arg) {
6295 apply(index, arg); 4129 apply(index, arg);
6296 return null; 4130 return null;
6297 } 4131 }
6298 4132
6299 @override 4133 @override
6300 R errorInvalidSetIfNull( 4134 R errorInvalidSetIfNull(Send node, ErroneousElement error, Node rhs, A arg) {
6301 Send node,
6302 ErroneousElement error,
6303 Node rhs,
6304 A arg) {
6305 apply(rhs, arg); 4135 apply(rhs, arg);
6306 return null; 4136 return null;
6307 } 4137 }
6308 4138
6309 @override 4139 @override
6310 R visitClassTypeLiteralSetIfNull( 4140 R visitClassTypeLiteralSetIfNull(
6311 Send node, 4141 Send node, ConstantExpression constant, Node rhs, A arg) {
6312 ConstantExpression constant,
6313 Node rhs,
6314 A arg) {
6315 apply(rhs, arg); 4142 apply(rhs, arg);
6316 return null; 4143 return null;
6317 } 4144 }
6318 4145
6319 @override 4146 @override
6320 R visitDynamicPropertySetIfNull( 4147 R visitDynamicPropertySetIfNull(
6321 Send node, 4148 Send node, Node receiver, Name name, Node rhs, A arg) {
6322 Node receiver,
6323 Name name,
6324 Node rhs,
6325 A arg) {
6326 apply(receiver, arg); 4149 apply(receiver, arg);
6327 apply(rhs, arg); 4150 apply(rhs, arg);
6328 return null; 4151 return null;
6329 } 4152 }
6330 4153
6331 @override 4154 @override
6332 R visitDynamicTypeLiteralSetIfNull( 4155 R visitDynamicTypeLiteralSetIfNull(
6333 Send node, 4156 Send node, ConstantExpression constant, Node rhs, A arg) {
6334 ConstantExpression constant,
6335 Node rhs,
6336 A arg) {
6337 apply(rhs, arg); 4157 apply(rhs, arg);
6338 return null; 4158 return null;
6339 } 4159 }
6340 4160
6341 @override 4161 @override
6342 R visitFinalLocalVariableSetIfNull( 4162 R visitFinalLocalVariableSetIfNull(
6343 Send node, 4163 Send node, LocalVariableElement variable, Node rhs, A arg) {
6344 LocalVariableElement variable,
6345 Node rhs,
6346 A arg) {
6347 apply(rhs, arg); 4164 apply(rhs, arg);
6348 return null; 4165 return null;
6349 } 4166 }
6350 4167
6351 @override 4168 @override
6352 R visitFinalParameterSetIfNull( 4169 R visitFinalParameterSetIfNull(
6353 Send node, 4170 Send node, ParameterElement parameter, Node rhs, A arg) {
6354 ParameterElement parameter,
6355 Node rhs,
6356 A arg) {
6357 apply(rhs, arg); 4171 apply(rhs, arg);
6358 return null; 4172 return null;
6359 } 4173 }
6360 4174
6361 @override 4175 @override
6362 R visitFinalStaticFieldSetIfNull( 4176 R visitFinalStaticFieldSetIfNull(
6363 Send node, 4177 Send node, FieldElement field, Node rhs, A arg) {
6364 FieldElement field,
6365 Node rhs,
6366 A arg) {
6367 apply(rhs, arg); 4178 apply(rhs, arg);
6368 return null; 4179 return null;
6369 } 4180 }
6370 4181
6371 @override 4182 @override
6372 R visitFinalSuperFieldSetIfNull( 4183 R visitFinalSuperFieldSetIfNull(
6373 Send node, 4184 Send node, FieldElement field, Node rhs, A arg) {
6374 FieldElement field,
6375 Node rhs,
6376 A arg) {
6377 apply(rhs, arg); 4185 apply(rhs, arg);
6378 return null; 4186 return null;
6379 } 4187 }
6380 4188
6381 @override 4189 @override
6382 R visitFinalTopLevelFieldSetIfNull( 4190 R visitFinalTopLevelFieldSetIfNull(
6383 Send node, 4191 Send node, FieldElement field, Node rhs, A arg) {
6384 FieldElement field,
6385 Node rhs,
6386 A arg) {
6387 apply(rhs, arg); 4192 apply(rhs, arg);
6388 return null; 4193 return null;
6389 } 4194 }
6390 4195
6391 @override 4196 @override
6392 R visitIfNotNullDynamicPropertySetIfNull( 4197 R visitIfNotNullDynamicPropertySetIfNull(
6393 Send node, 4198 Send node, Node receiver, Name name, Node rhs, A arg) {
6394 Node receiver,
6395 Name name,
6396 Node rhs,
6397 A arg) {
6398 apply(receiver, arg); 4199 apply(receiver, arg);
6399 apply(rhs, arg); 4200 apply(rhs, arg);
6400 return null; 4201 return null;
6401 } 4202 }
6402 4203
6403 @override 4204 @override
6404 R visitLocalFunctionSetIfNull( 4205 R visitLocalFunctionSetIfNull(
6405 Send node, 4206 Send node, LocalFunctionElement function, Node rhs, A arg) {
6406 LocalFunctionElement function,
6407 Node rhs,
6408 A arg) {
6409 apply(rhs, arg); 4207 apply(rhs, arg);
6410 return null; 4208 return null;
6411 } 4209 }
6412 4210
6413 @override 4211 @override
6414 R visitLocalVariableSetIfNull( 4212 R visitLocalVariableSetIfNull(
6415 Send node, 4213 Send node, LocalVariableElement variable, Node rhs, A arg) {
6416 LocalVariableElement variable,
6417 Node rhs,
6418 A arg) {
6419 apply(rhs, arg); 4214 apply(rhs, arg);
6420 return null; 4215 return null;
6421 } 4216 }
6422 4217
6423 @override 4218 @override
6424 R visitParameterSetIfNull( 4219 R visitParameterSetIfNull(
6425 Send node, 4220 Send node, ParameterElement parameter, Node rhs, A arg) {
6426 ParameterElement parameter, 4221 apply(rhs, arg);
6427 Node rhs, 4222 return null;
6428 A arg) { 4223 }
6429 apply(rhs, arg); 4224
6430 return null; 4225 @override
6431 } 4226 R visitStaticFieldSetIfNull(Send node, FieldElement field, Node rhs, A arg) {
6432 4227 apply(rhs, arg);
6433 @override 4228 return null;
6434 R visitStaticFieldSetIfNull( 4229 }
6435 Send node, 4230
6436 FieldElement field, 4231 @override
6437 Node rhs, 4232 R visitStaticGetterSetterSetIfNull(Send node, FunctionElement getter,
6438 A arg) { 4233 FunctionElement setter, Node rhs, A arg) {
6439 apply(rhs, arg);
6440 return null;
6441 }
6442
6443 @override
6444 R visitStaticGetterSetterSetIfNull(
6445 Send node,
6446 FunctionElement getter,
6447 FunctionElement setter,
6448 Node rhs,
6449 A arg) {
6450 apply(rhs, arg); 4234 apply(rhs, arg);
6451 return null; 4235 return null;
6452 } 4236 }
6453 4237
6454 @override 4238 @override
6455 R visitStaticMethodSetIfNull( 4239 R visitStaticMethodSetIfNull(
6456 Send node, 4240 Send node, FunctionElement method, Node rhs, A arg) {
6457 FunctionElement method,
6458 Node rhs,
6459 A arg) {
6460 apply(rhs, arg); 4241 apply(rhs, arg);
6461 return null; 4242 return null;
6462 } 4243 }
6463 4244
6464 @override 4245 @override
6465 R visitStaticMethodSetterSetIfNull( 4246 R visitStaticMethodSetterSetIfNull(
6466 Send node, 4247 Send node, MethodElement method, MethodElement setter, Node rhs, A arg) {
6467 MethodElement method, 4248 apply(rhs, arg);
6468 MethodElement setter, 4249 return null;
6469 Node rhs, 4250 }
6470 A arg) { 4251
6471 apply(rhs, arg); 4252 @override
6472 return null; 4253 R visitSuperFieldFieldSetIfNull(Send node, FieldElement readField,
6473 } 4254 FieldElement writtenField, Node rhs, A arg) {
6474 4255 apply(rhs, arg);
6475 @override 4256 return null;
6476 R visitSuperFieldFieldSetIfNull( 4257 }
6477 Send node, 4258
6478 FieldElement readField, 4259 @override
6479 FieldElement writtenField, 4260 R visitSuperFieldSetIfNull(Send node, FieldElement field, Node rhs, A arg) {
6480 Node rhs,
6481 A arg) {
6482 apply(rhs, arg);
6483 return null;
6484 }
6485
6486 @override
6487 R visitSuperFieldSetIfNull(
6488 Send node,
6489 FieldElement field,
6490 Node rhs,
6491 A arg) {
6492 apply(rhs, arg); 4261 apply(rhs, arg);
6493 return null; 4262 return null;
6494 } 4263 }
6495 4264
6496 @override 4265 @override
6497 R visitSuperFieldSetterSetIfNull( 4266 R visitSuperFieldSetterSetIfNull(
6498 Send node, 4267 Send node, FieldElement field, FunctionElement setter, Node rhs, A arg) {
6499 FieldElement field,
6500 FunctionElement setter,
6501 Node rhs,
6502 A arg) {
6503 apply(rhs, arg); 4268 apply(rhs, arg);
6504 return null; 4269 return null;
6505 } 4270 }
6506 4271
6507 @override 4272 @override
6508 R visitSuperGetterFieldSetIfNull( 4273 R visitSuperGetterFieldSetIfNull(
6509 Send node, 4274 Send node, FunctionElement getter, FieldElement field, Node rhs, A arg) {
6510 FunctionElement getter, 4275 apply(rhs, arg);
6511 FieldElement field, 4276 return null;
6512 Node rhs, 4277 }
6513 A arg) { 4278
6514 apply(rhs, arg); 4279 @override
6515 return null; 4280 R visitSuperGetterSetterSetIfNull(Send node, FunctionElement getter,
6516 } 4281 FunctionElement setter, Node rhs, A arg) {
6517
6518 @override
6519 R visitSuperGetterSetterSetIfNull(
6520 Send node,
6521 FunctionElement getter,
6522 FunctionElement setter,
6523 Node rhs,
6524 A arg) {
6525 apply(rhs, arg); 4282 apply(rhs, arg);
6526 return null; 4283 return null;
6527 } 4284 }
6528 4285
6529 @override 4286 @override
6530 R visitSuperMethodSetIfNull( 4287 R visitSuperMethodSetIfNull(
6531 Send node, 4288 Send node, FunctionElement method, Node rhs, A arg) {
6532 FunctionElement method, 4289 apply(rhs, arg);
6533 Node rhs, 4290 return null;
6534 A arg) { 4291 }
6535 apply(rhs, arg); 4292
6536 return null; 4293 @override
6537 } 4294 R visitSuperMethodSetterSetIfNull(Send node, FunctionElement method,
6538 4295 FunctionElement setter, Node rhs, A arg) {
6539 @override 4296 apply(rhs, arg);
6540 R visitSuperMethodSetterSetIfNull( 4297 return null;
6541 Send node, 4298 }
6542 FunctionElement method, 4299
6543 FunctionElement setter, 4300 @override
6544 Node rhs, 4301 R visitThisPropertySetIfNull(Send node, Name name, Node rhs, A arg) {
6545 A arg) {
6546 apply(rhs, arg);
6547 return null;
6548 }
6549
6550 @override
6551 R visitThisPropertySetIfNull(
6552 Send node,
6553 Name name,
6554 Node rhs,
6555 A arg) {
6556 apply(rhs, arg); 4302 apply(rhs, arg);
6557 return null; 4303 return null;
6558 } 4304 }
6559 4305
6560 @override 4306 @override
6561 R visitTopLevelFieldSetIfNull( 4307 R visitTopLevelFieldSetIfNull(
6562 Send node, 4308 Send node, FieldElement field, Node rhs, A arg) {
6563 FieldElement field, 4309 apply(rhs, arg);
6564 Node rhs, 4310 return null;
6565 A arg) { 4311 }
6566 apply(rhs, arg); 4312
6567 return null; 4313 @override
6568 } 4314 R visitTopLevelGetterSetterSetIfNull(Send node, FunctionElement getter,
6569 4315 FunctionElement setter, Node rhs, A arg) {
6570 @override
6571 R visitTopLevelGetterSetterSetIfNull(
6572 Send node,
6573 FunctionElement getter,
6574 FunctionElement setter,
6575 Node rhs,
6576 A arg) {
6577 apply(rhs, arg); 4316 apply(rhs, arg);
6578 return null; 4317 return null;
6579 } 4318 }
6580 4319
6581 @override 4320 @override
6582 R visitTopLevelMethodSetIfNull( 4321 R visitTopLevelMethodSetIfNull(
6583 Send node, 4322 Send node, FunctionElement method, Node rhs, A arg) {
6584 FunctionElement method, 4323 apply(rhs, arg);
6585 Node rhs, 4324 return null;
6586 A arg) { 4325 }
6587 apply(rhs, arg); 4326
6588 return null; 4327 @override
6589 } 4328 R visitTopLevelMethodSetterSetIfNull(Send node, FunctionElement method,
6590 4329 FunctionElement setter, Node rhs, A arg) {
6591 @override
6592 R visitTopLevelMethodSetterSetIfNull(
6593 Send node,
6594 FunctionElement method,
6595 FunctionElement setter,
6596 Node rhs,
6597 A arg) {
6598 apply(rhs, arg); 4330 apply(rhs, arg);
6599 return null; 4331 return null;
6600 } 4332 }
6601 4333
6602 @override 4334 @override
6603 R visitTypeVariableTypeLiteralSetIfNull( 4335 R visitTypeVariableTypeLiteralSetIfNull(
6604 Send node, 4336 Send node, TypeVariableElement element, Node rhs, A arg) {
6605 TypeVariableElement element,
6606 Node rhs,
6607 A arg) {
6608 apply(rhs, arg); 4337 apply(rhs, arg);
6609 return null; 4338 return null;
6610 } 4339 }
6611 4340
6612 @override 4341 @override
6613 R visitTypedefTypeLiteralSetIfNull( 4342 R visitTypedefTypeLiteralSetIfNull(
6614 Send node, 4343 Send node, ConstantExpression constant, Node rhs, A arg) {
6615 ConstantExpression constant, 4344 apply(rhs, arg);
6616 Node rhs, 4345 return null;
6617 A arg) { 4346 }
6618 apply(rhs, arg); 4347
6619 return null; 4348 @override
6620 } 4349 R visitUnresolvedSetIfNull(Send node, Element element, Node rhs, A arg) {
6621
6622 @override
6623 R visitUnresolvedSetIfNull(
6624 Send node,
6625 Element element,
6626 Node rhs,
6627 A arg) {
6628 apply(rhs, arg); 4350 apply(rhs, arg);
6629 return null; 4351 return null;
6630 } 4352 }
6631 4353
6632 @override 4354 @override
6633 R visitUnresolvedStaticGetterSetIfNull( 4355 R visitUnresolvedStaticGetterSetIfNull(
6634 Send node, 4356 Send node, Element element, MethodElement setter, Node rhs, A arg) {
6635 Element element,
6636 MethodElement setter,
6637 Node rhs,
6638 A arg) {
6639 apply(rhs, arg); 4357 apply(rhs, arg);
6640 return null; 4358 return null;
6641 } 4359 }
6642 4360
6643 @override 4361 @override
6644 R visitUnresolvedStaticSetterSetIfNull( 4362 R visitUnresolvedStaticSetterSetIfNull(
6645 Send node, 4363 Send node, MethodElement getter, Element element, Node rhs, A arg) {
6646 MethodElement getter,
6647 Element element,
6648 Node rhs,
6649 A arg) {
6650 apply(rhs, arg); 4364 apply(rhs, arg);
6651 return null; 4365 return null;
6652 } 4366 }
6653 4367
6654 @override 4368 @override
6655 R visitUnresolvedSuperGetterSetIfNull( 4369 R visitUnresolvedSuperGetterSetIfNull(
6656 Send node, 4370 Send node, Element element, MethodElement setter, Node rhs, A arg) {
6657 Element element, 4371 apply(rhs, arg);
6658 MethodElement setter, 4372 return null;
6659 Node rhs, 4373 }
6660 A arg) { 4374
6661 apply(rhs, arg); 4375 @override
6662 return null; 4376 R visitUnresolvedSuperSetIfNull(Send node, Element element, Node rhs, A arg) {
6663 }
6664
6665 @override
6666 R visitUnresolvedSuperSetIfNull(
6667 Send node,
6668 Element element,
6669 Node rhs,
6670 A arg) {
6671 apply(rhs, arg); 4377 apply(rhs, arg);
6672 return null; 4378 return null;
6673 } 4379 }
6674 4380
6675 @override 4381 @override
6676 R visitUnresolvedSuperSetterSetIfNull( 4382 R visitUnresolvedSuperSetterSetIfNull(
6677 Send node, 4383 Send node, MethodElement getter, Element element, Node rhs, A arg) {
6678 MethodElement getter,
6679 Element element,
6680 Node rhs,
6681 A arg) {
6682 apply(rhs, arg); 4384 apply(rhs, arg);
6683 return null; 4385 return null;
6684 } 4386 }
6685 4387
6686 @override 4388 @override
6687 R visitUnresolvedTopLevelGetterSetIfNull( 4389 R visitUnresolvedTopLevelGetterSetIfNull(
6688 Send node, 4390 Send node, Element element, MethodElement setter, Node rhs, A arg) {
6689 Element element,
6690 MethodElement setter,
6691 Node rhs,
6692 A arg) {
6693 apply(rhs, arg); 4391 apply(rhs, arg);
6694 return null; 4392 return null;
6695 } 4393 }
6696 4394
6697 @override 4395 @override
6698 R visitUnresolvedTopLevelSetterSetIfNull( 4396 R visitUnresolvedTopLevelSetterSetIfNull(
6699 Send node, 4397 Send node, MethodElement getter, Element element, Node rhs, A arg) {
6700 MethodElement getter,
6701 Element element,
6702 Node rhs,
6703 A arg) {
6704 apply(rhs, arg); 4398 apply(rhs, arg);
6705 return null; 4399 return null;
6706 } 4400 }
6707 4401
6708 @override 4402 @override
6709 R visitConstConstructorInvoke( 4403 R visitConstConstructorInvoke(
6710 NewExpression node, 4404 NewExpression node, ConstructedConstantExpression constant, A arg) {
6711 ConstructedConstantExpression constant, 4405 return null;
6712 A arg) { 4406 }
6713 return null; 4407
6714 } 4408 @override
6715 4409 R visitBoolFromEnvironmentConstructorInvoke(NewExpression node,
6716 @override 4410 BoolFromEnvironmentConstantExpression constant, A arg) {
6717 R visitBoolFromEnvironmentConstructorInvoke( 4411 return null;
6718 NewExpression node, 4412 }
6719 BoolFromEnvironmentConstantExpression constant, 4413
6720 A arg) { 4414 @override
6721 return null; 4415 R visitIntFromEnvironmentConstructorInvoke(NewExpression node,
6722 } 4416 IntFromEnvironmentConstantExpression constant, A arg) {
6723 4417 return null;
6724 @override 4418 }
6725 R visitIntFromEnvironmentConstructorInvoke( 4419
6726 NewExpression node, 4420 @override
6727 IntFromEnvironmentConstantExpression constant, 4421 R visitStringFromEnvironmentConstructorInvoke(NewExpression node,
6728 A arg) { 4422 StringFromEnvironmentConstantExpression constant, A arg) {
6729 return null; 4423 return null;
6730 } 4424 }
6731 4425
6732 @override
6733 R visitStringFromEnvironmentConstructorInvoke(
6734 NewExpression node,
6735 StringFromEnvironmentConstantExpression constant,
6736 A arg) {
6737 return null;
6738 }
6739
6740 @override 4426 @override
6741 R visitConstructorIncompatibleInvoke( 4427 R visitConstructorIncompatibleInvoke(
6742 NewExpression node, 4428 NewExpression node,
6743 ConstructorElement constructor, 4429 ConstructorElement constructor,
6744 InterfaceType type, 4430 InterfaceType type,
6745 NodeList arguments, 4431 NodeList arguments,
6746 CallStructure callStructure, 4432 CallStructure callStructure,
6747 A arg) { 4433 A arg) {
6748 apply(arguments, arg); 4434 apply(arguments, arg);
6749 return null; 4435 return null;
6750 } 4436 }
6751 4437
6752 @override 4438 @override
6753 R visitUnresolvedClassConstructorInvoke( 4439 R visitUnresolvedClassConstructorInvoke(
6754 NewExpression node, 4440 NewExpression node,
6755 Element constructor, 4441 Element constructor,
6756 DartType type, 4442 DartType type,
6757 NodeList arguments, 4443 NodeList arguments,
6758 Selector selector, 4444 Selector selector,
6759 A arg) { 4445 A arg) {
6760 apply(arguments, arg); 4446 apply(arguments, arg);
6761 return null; 4447 return null;
6762 } 4448 }
6763 4449
6764 @override 4450 @override
6765 R visitUnresolvedConstructorInvoke( 4451 R visitUnresolvedConstructorInvoke(NewExpression node, Element constructor,
6766 NewExpression node, 4452 DartType type, NodeList arguments, Selector selector, A arg) {
6767 Element constructor,
6768 DartType type,
6769 NodeList arguments,
6770 Selector selector,
6771 A arg) {
6772 apply(arguments, arg); 4453 apply(arguments, arg);
6773 return null; 4454 return null;
6774 } 4455 }
6775 4456
6776 @override 4457 @override
6777 R visitFactoryConstructorInvoke( 4458 R visitFactoryConstructorInvoke(
6778 NewExpression node, 4459 NewExpression node,
6779 ConstructorElement constructor, 4460 ConstructorElement constructor,
6780 InterfaceType type, 4461 InterfaceType type,
6781 NodeList arguments, 4462 NodeList arguments,
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
6841 ConstructorElement constructor, 4522 ConstructorElement constructor,
6842 InterfaceType type, 4523 InterfaceType type,
6843 NodeList arguments, 4524 NodeList arguments,
6844 CallStructure callStructure, 4525 CallStructure callStructure,
6845 A arg) { 4526 A arg) {
6846 apply(arguments, arg); 4527 apply(arguments, arg);
6847 return null; 4528 return null;
6848 } 4529 }
6849 4530
6850 @override 4531 @override
6851 R errorNonConstantConstructorInvoke( 4532 R errorNonConstantConstructorInvoke(NewExpression node, Element element,
6852 NewExpression node, 4533 DartType type, NodeList arguments, CallStructure callStructure, A arg) {
6853 Element element,
6854 DartType type,
6855 NodeList arguments,
6856 CallStructure callStructure,
6857 A arg) {
6858 apply(arguments, arg); 4534 apply(arguments, arg);
6859 return null; 4535 return null;
6860 } 4536 }
6861 4537
6862 @override 4538 @override
6863 R visitUnresolvedStaticGetterCompound( 4539 R visitUnresolvedStaticGetterCompound(Send node, Element element,
6864 Send node, 4540 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
6865 Element element, 4541 apply(rhs, arg);
6866 MethodElement setter, 4542 return null;
6867 AssignmentOperator operator, 4543 }
6868 Node rhs, 4544
6869 A arg) { 4545 @override
6870 apply(rhs, arg); 4546 R visitUnresolvedTopLevelGetterCompound(Send node, Element element,
6871 return null; 4547 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
6872 } 4548 apply(rhs, arg);
6873 4549 return null;
6874 @override 4550 }
6875 R visitUnresolvedTopLevelGetterCompound( 4551
6876 Send node, 4552 @override
6877 Element element, 4553 R visitUnresolvedStaticSetterCompound(Send node, MethodElement getter,
6878 MethodElement setter, 4554 Element element, AssignmentOperator operator, Node rhs, A arg) {
6879 AssignmentOperator operator, 4555 apply(rhs, arg);
6880 Node rhs, 4556 return null;
6881 A arg) { 4557 }
6882 apply(rhs, arg); 4558
6883 return null; 4559 @override
6884 } 4560 R visitUnresolvedTopLevelSetterCompound(Send node, MethodElement getter,
6885 4561 Element element, AssignmentOperator operator, Node rhs, A arg) {
6886 @override 4562 apply(rhs, arg);
6887 R visitUnresolvedStaticSetterCompound( 4563 return null;
6888 Send node, 4564 }
6889 MethodElement getter, 4565
6890 Element element, 4566 @override
6891 AssignmentOperator operator, 4567 R visitStaticMethodCompound(Send node, MethodElement method,
6892 Node rhs, 4568 AssignmentOperator operator, Node rhs, A arg) {
6893 A arg) { 4569 apply(rhs, arg);
6894 apply(rhs, arg); 4570 return null;
6895 return null; 4571 }
6896 } 4572
6897 4573 @override
6898 @override 4574 R visitUnresolvedStaticGetterPrefix(Send node, Element element,
6899 R visitUnresolvedTopLevelSetterCompound( 4575 MethodElement setter, IncDecOperator operator, A arg) {
6900 Send node, 4576 return null;
6901 MethodElement getter, 4577 }
6902 Element element, 4578
6903 AssignmentOperator operator, 4579 @override
6904 Node rhs, 4580 R visitUnresolvedTopLevelGetterPrefix(Send node, Element element,
6905 A arg) { 4581 MethodElement setter, IncDecOperator operator, A arg) {
6906 apply(rhs, arg); 4582 return null;
6907 return null; 4583 }
6908 } 4584
6909 4585 @override
6910 @override 4586 R visitUnresolvedStaticSetterPrefix(Send node, MethodElement getter,
6911 R visitStaticMethodCompound( 4587 Element element, IncDecOperator operator, A arg) {
6912 Send node, 4588 return null;
6913 MethodElement method, 4589 }
6914 AssignmentOperator operator, 4590
6915 Node rhs, 4591 @override
6916 A arg) { 4592 R visitUnresolvedTopLevelSetterPrefix(Send node, MethodElement getter,
6917 apply(rhs, arg); 4593 Element element, IncDecOperator operator, A arg) {
6918 return null;
6919 }
6920
6921 @override
6922 R visitUnresolvedStaticGetterPrefix(
6923 Send node,
6924 Element element,
6925 MethodElement setter,
6926 IncDecOperator operator,
6927 A arg) {
6928 return null;
6929 }
6930
6931 @override
6932 R visitUnresolvedTopLevelGetterPrefix(
6933 Send node,
6934 Element element,
6935 MethodElement setter,
6936 IncDecOperator operator,
6937 A arg) {
6938 return null;
6939 }
6940
6941 @override
6942 R visitUnresolvedStaticSetterPrefix(
6943 Send node,
6944 MethodElement getter,
6945 Element element,
6946 IncDecOperator operator,
6947 A arg) {
6948 return null;
6949 }
6950
6951 @override
6952 R visitUnresolvedTopLevelSetterPrefix(
6953 Send node,
6954 MethodElement getter,
6955 Element element,
6956 IncDecOperator operator,
6957 A arg) {
6958 return null; 4594 return null;
6959 } 4595 }
6960 4596
6961 @override 4597 @override
6962 R visitStaticMethodPrefix( 4598 R visitStaticMethodPrefix(
6963 Send node, 4599 Send node, MethodElement method, IncDecOperator operator, A arg) {
6964 MethodElement method,
6965 IncDecOperator operator,
6966 A arg) {
6967 return null; 4600 return null;
6968 } 4601 }
6969 4602
6970 @override 4603 @override
6971 R visitTopLevelMethodPrefix( 4604 R visitTopLevelMethodPrefix(
6972 Send node, 4605 Send node, MethodElement method, IncDecOperator operator, A arg) {
6973 MethodElement method, 4606 return null;
6974 IncDecOperator operator, 4607 }
6975 A arg) { 4608
6976 return null; 4609 @override
6977 } 4610 R visitUnresolvedStaticGetterPostfix(Send node, Element element,
6978 4611 MethodElement setter, IncDecOperator operator, A arg) {
6979 @override 4612 return null;
6980 R visitUnresolvedStaticGetterPostfix( 4613 }
6981 Send node, 4614
6982 Element element, 4615 @override
6983 MethodElement setter, 4616 R visitUnresolvedTopLevelGetterPostfix(Send node, Element element,
6984 IncDecOperator operator, 4617 MethodElement setter, IncDecOperator operator, A arg) {
6985 A arg) { 4618 return null;
6986 return null; 4619 }
6987 } 4620
6988 4621 @override
6989 @override 4622 R visitUnresolvedStaticSetterPostfix(Send node, MethodElement getter,
6990 R visitUnresolvedTopLevelGetterPostfix( 4623 Element element, IncDecOperator operator, A arg) {
6991 Send node, 4624 return null;
6992 Element element, 4625 }
6993 MethodElement setter, 4626
6994 IncDecOperator operator, 4627 @override
6995 A arg) { 4628 R visitUnresolvedTopLevelSetterPostfix(Send node, MethodElement getter,
6996 return null; 4629 Element element, IncDecOperator operator, A arg) {
6997 }
6998
6999 @override
7000 R visitUnresolvedStaticSetterPostfix(
7001 Send node,
7002 MethodElement getter,
7003 Element element,
7004 IncDecOperator operator,
7005 A arg) {
7006 return null;
7007 }
7008
7009 @override
7010 R visitUnresolvedTopLevelSetterPostfix(
7011 Send node,
7012 MethodElement getter,
7013 Element element,
7014 IncDecOperator operator,
7015 A arg) {
7016 return null; 4630 return null;
7017 } 4631 }
7018 4632
7019 @override 4633 @override
7020 R visitStaticMethodPostfix( 4634 R visitStaticMethodPostfix(
7021 Send node, 4635 Send node, MethodElement method, IncDecOperator operator, A arg) {
7022 MethodElement method,
7023 IncDecOperator operator,
7024 A arg) {
7025 return null; 4636 return null;
7026 } 4637 }
7027 4638
7028 @override 4639 @override
7029 R visitTopLevelMethodPostfix( 4640 R visitTopLevelMethodPostfix(
7030 Send node, 4641 Send node, MethodElement method, IncDecOperator operator, A arg) {
7031 MethodElement method, 4642 return null;
7032 IncDecOperator operator, 4643 }
7033 A arg) { 4644
7034 return null; 4645 @override
7035 } 4646 R visitFinalLocalVariablePostfix(Send node, LocalVariableElement variable,
7036 4647 IncDecOperator operator, A arg) {
7037 @override 4648 return null;
7038 R visitFinalLocalVariablePostfix( 4649 }
7039 Send node, 4650
7040 LocalVariableElement variable, 4651 @override
7041 IncDecOperator operator, 4652 R visitFinalLocalVariablePrefix(Send node, LocalVariableElement variable,
7042 A arg) { 4653 IncDecOperator operator, A arg) {
7043 return null;
7044 }
7045
7046 @override
7047 R visitFinalLocalVariablePrefix(
7048 Send node,
7049 LocalVariableElement variable,
7050 IncDecOperator operator,
7051 A arg) {
7052 return null; 4654 return null;
7053 } 4655 }
7054 4656
7055 @override 4657 @override
7056 R visitFinalParameterPostfix( 4658 R visitFinalParameterPostfix(
7057 Send node, 4659 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
7058 ParameterElement parameter,
7059 IncDecOperator operator,
7060 A arg) {
7061 return null; 4660 return null;
7062 } 4661 }
7063 4662
7064 @override 4663 @override
7065 R visitFinalParameterPrefix( 4664 R visitFinalParameterPrefix(
7066 Send node, 4665 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
7067 ParameterElement parameter,
7068 IncDecOperator operator,
7069 A arg) {
7070 return null; 4666 return null;
7071 } 4667 }
7072 4668
7073 @override 4669 @override
7074 R visitFinalStaticFieldPostfix( 4670 R visitFinalStaticFieldPostfix(
7075 Send node, 4671 Send node, FieldElement field, IncDecOperator operator, A arg) {
7076 FieldElement field,
7077 IncDecOperator operator,
7078 A arg) {
7079 return null; 4672 return null;
7080 } 4673 }
7081 4674
7082 @override 4675 @override
7083 R visitFinalStaticFieldPrefix( 4676 R visitFinalStaticFieldPrefix(
7084 Send node, 4677 Send node, FieldElement field, IncDecOperator operator, A arg) {
7085 FieldElement field, 4678 return null;
7086 IncDecOperator operator, 4679 }
7087 A arg) { 4680
7088 return null; 4681 @override
7089 } 4682 R visitSuperFieldFieldCompound(Send node, FieldElement readField,
7090 4683 FieldElement writtenField, AssignmentOperator operator, Node rhs, A arg) {
7091 @override 4684 apply(rhs, arg);
7092 R visitSuperFieldFieldCompound( 4685 return null;
7093 Send node, FieldElement readField, 4686 }
7094 FieldElement writtenField, 4687
7095 AssignmentOperator operator, 4688 @override
7096 Node rhs, 4689 R visitFinalSuperFieldCompound(Send node, FieldElement field,
7097 A arg) { 4690 AssignmentOperator operator, Node rhs, A arg) {
7098 apply(rhs, arg);
7099 return null;
7100 }
7101
7102 @override
7103 R visitFinalSuperFieldCompound(
7104 Send node,
7105 FieldElement field,
7106 AssignmentOperator operator,
7107 Node rhs,
7108 A arg) {
7109 apply(rhs, arg); 4691 apply(rhs, arg);
7110 return null; 4692 return null;
7111 } 4693 }
7112 4694
7113 @override 4695 @override
7114 R visitFinalSuperFieldPostfix( 4696 R visitFinalSuperFieldPostfix(
7115 Send node, 4697 Send node, FieldElement field, IncDecOperator operator, A arg) {
7116 FieldElement field,
7117 IncDecOperator operator,
7118 A arg) {
7119 return null; 4698 return null;
7120 } 4699 }
7121 4700
7122 @override 4701 @override
7123 R visitFinalSuperFieldPrefix( 4702 R visitFinalSuperFieldPrefix(
7124 Send node, 4703 Send node, FieldElement field, IncDecOperator operator, A arg) {
7125 FieldElement field, 4704 return null;
7126 IncDecOperator operator, 4705 }
7127 A arg) { 4706
7128 return null; 4707 @override
7129 } 4708 R visitSuperMethodCompound(Send node, FunctionElement method,
7130 4709 AssignmentOperator operator, Node rhs, A arg) {
7131 @override
7132 R visitSuperMethodCompound(
7133 Send node,
7134 FunctionElement method,
7135 AssignmentOperator operator,
7136 Node rhs,
7137 A arg) {
7138 apply(rhs, arg); 4710 apply(rhs, arg);
7139 return null; 4711 return null;
7140 } 4712 }
7141 4713
7142 @override 4714 @override
7143 R visitSuperMethodPostfix( 4715 R visitSuperMethodPostfix(
7144 Send node, 4716 Send node, FunctionElement method, IncDecOperator operator, A arg) {
7145 FunctionElement method,
7146 IncDecOperator operator,
7147 A arg) {
7148 return null; 4717 return null;
7149 } 4718 }
7150 4719
7151 @override 4720 @override
7152 R visitSuperMethodPrefix( 4721 R visitSuperMethodPrefix(
7153 Send node, 4722 Send node, FunctionElement method, IncDecOperator operator, A arg) {
7154 FunctionElement method,
7155 IncDecOperator operator,
7156 A arg) {
7157 return null; 4723 return null;
7158 } 4724 }
7159 4725
7160 @override 4726 @override
7161 R visitFinalTopLevelFieldPostfix( 4727 R visitFinalTopLevelFieldPostfix(
7162 Send node, 4728 Send node, FieldElement field, IncDecOperator operator, A arg) {
7163 FieldElement field,
7164 IncDecOperator operator,
7165 A arg) {
7166 return null; 4729 return null;
7167 } 4730 }
7168 4731
7169 @override 4732 @override
7170 R visitFinalTopLevelFieldPrefix( 4733 R visitFinalTopLevelFieldPrefix(
7171 Send node, 4734 Send node, FieldElement field, IncDecOperator operator, A arg) {
7172 FieldElement field, 4735 return null;
7173 IncDecOperator operator, 4736 }
7174 A arg) { 4737
7175 return null; 4738 @override
7176 } 4739 R visitTopLevelMethodCompound(Send node, FunctionElement method,
7177 4740 AssignmentOperator operator, Node rhs, A arg) {
7178 @override 4741 apply(rhs, arg);
7179 R visitTopLevelMethodCompound( 4742 return null;
7180 Send node, 4743 }
7181 FunctionElement method, 4744
7182 AssignmentOperator operator, 4745 @override
7183 Node rhs, 4746 R visitUnresolvedSuperCompound(Send node, Element element,
7184 A arg) { 4747 AssignmentOperator operator, Node rhs, A arg) {
7185 apply(rhs, arg);
7186 return null;
7187 }
7188
7189 @override
7190 R visitUnresolvedSuperCompound(
7191 Send node,
7192 Element element,
7193 AssignmentOperator operator,
7194 Node rhs,
7195 A arg) {
7196 apply(rhs, arg); 4748 apply(rhs, arg);
7197 return null; 4749 return null;
7198 } 4750 }
7199 4751
7200 @override 4752 @override
7201 R visitUnresolvedSuperPostfix( 4753 R visitUnresolvedSuperPostfix(
7202 Send node, 4754 Send node, Element element, IncDecOperator operator, A arg) {
7203 Element element,
7204 IncDecOperator operator,
7205 A arg) {
7206 return null; 4755 return null;
7207 } 4756 }
7208 4757
7209 @override 4758 @override
7210 R visitUnresolvedSuperPrefix( 4759 R visitUnresolvedSuperPrefix(
7211 Send node, 4760 Send node, Element element, IncDecOperator operator, A arg) {
7212 Element element, 4761 return null;
7213 IncDecOperator operator, 4762 }
7214 A arg) { 4763
7215 return null; 4764 @override
7216 } 4765 R visitUnresolvedSuperGetterCompound(Send node, Element element,
7217 4766 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
7218 @override 4767 apply(rhs, arg);
7219 R visitUnresolvedSuperGetterCompound( 4768 return null;
7220 Send node, Element element, 4769 }
7221 MethodElement setter, 4770
7222 AssignmentOperator operator, 4771 @override
7223 Node rhs, 4772 R visitUnresolvedSuperGetterPostfix(Send node, Element element,
7224 A arg) { 4773 MethodElement setter, IncDecOperator operator, A arg) {
7225 apply(rhs, arg); 4774 return null;
7226 return null; 4775 }
7227 } 4776
7228 4777 @override
7229 @override 4778 R visitUnresolvedSuperGetterPrefix(Send node, Element element,
7230 R visitUnresolvedSuperGetterPostfix( 4779 MethodElement setter, IncDecOperator operator, A arg) {
7231 Send node, 4780 return null;
7232 Element element, 4781 }
7233 MethodElement setter, 4782
7234 IncDecOperator operator, 4783 @override
7235 A arg) { 4784 R visitUnresolvedSuperSetterCompound(Send node, MethodElement getter,
7236 return null; 4785 Element element, AssignmentOperator operator, Node rhs, A arg) {
7237 } 4786 apply(rhs, arg);
7238 4787 return null;
7239 @override 4788 }
7240 R visitUnresolvedSuperGetterPrefix( 4789
7241 Send node, 4790 @override
7242 Element element, 4791 R visitUnresolvedSuperSetterPostfix(Send node, MethodElement getter,
7243 MethodElement setter, 4792 Element element, IncDecOperator operator, A arg) {
7244 IncDecOperator operator, 4793 return null;
7245 A arg) { 4794 }
7246 return null; 4795
7247 } 4796 @override
7248 4797 R visitUnresolvedSuperSetterPrefix(Send node, MethodElement getter,
7249 @override 4798 Element element, IncDecOperator operator, A arg) {
7250 R visitUnresolvedSuperSetterCompound(
7251 Send node, MethodElement getter,
7252 Element element,
7253 AssignmentOperator operator,
7254 Node rhs,
7255 A arg) {
7256 apply(rhs, arg);
7257 return null;
7258 }
7259
7260 @override
7261 R visitUnresolvedSuperSetterPostfix(
7262 Send node,
7263 MethodElement getter,
7264 Element element,
7265 IncDecOperator operator,
7266 A arg) {
7267 return null;
7268 }
7269
7270 @override
7271 R visitUnresolvedSuperSetterPrefix(
7272 Send node,
7273 MethodElement getter,
7274 Element element,
7275 IncDecOperator operator,
7276 A arg) {
7277 return null; 4799 return null;
7278 } 4800 }
7279 4801
7280 @override 4802 @override
7281 R visitIndexSetIfNull( 4803 R visitIndexSetIfNull(
7282 SendSet node, 4804 SendSet node, Node receiver, Node index, Node rhs, A arg) {
7283 Node receiver,
7284 Node index,
7285 Node rhs,
7286 A arg) {
7287 apply(receiver, arg); 4805 apply(receiver, arg);
7288 apply(index, arg); 4806 apply(index, arg);
7289 apply(rhs, arg); 4807 apply(rhs, arg);
7290 return null; 4808 return null;
7291 } 4809 }
7292 4810
7293 @override 4811 @override
7294 R visitSuperIndexSetIfNull( 4812 R visitSuperIndexSetIfNull(SendSet node, MethodElement getter,
7295 SendSet node, 4813 MethodElement setter, Node index, Node rhs, A arg) {
7296 MethodElement getter,
7297 MethodElement setter,
7298 Node index,
7299 Node rhs,
7300 A arg) {
7301 apply(index, arg); 4814 apply(index, arg);
7302 apply(rhs, arg); 4815 apply(rhs, arg);
7303 return null; 4816 return null;
7304 } 4817 }
7305 4818
7306 @override 4819 @override
7307 R visitUnresolvedSuperGetterIndexSetIfNull( 4820 R visitUnresolvedSuperGetterIndexSetIfNull(Send node, Element element,
7308 Send node, 4821 MethodElement setter, Node index, Node rhs, A arg) {
7309 Element element,
7310 MethodElement setter,
7311 Node index,
7312 Node rhs,
7313 A arg) {
7314 apply(index, arg); 4822 apply(index, arg);
7315 apply(rhs, arg); 4823 apply(rhs, arg);
7316 return null; 4824 return null;
7317 } 4825 }
7318 4826
7319 @override 4827 @override
7320 R visitUnresolvedSuperSetterIndexSetIfNull( 4828 R visitUnresolvedSuperSetterIndexSetIfNull(Send node, MethodElement getter,
7321 Send node, 4829 Element element, Node index, Node rhs, A arg) {
7322 MethodElement getter,
7323 Element element,
7324 Node index,
7325 Node rhs,
7326 A arg) {
7327 apply(index, arg); 4830 apply(index, arg);
7328 apply(rhs, arg); 4831 apply(rhs, arg);
7329 return null; 4832 return null;
7330 } 4833 }
7331 4834
7332
7333 @override 4835 @override
7334 R visitUnresolvedSuperIndexSetIfNull( 4836 R visitUnresolvedSuperIndexSetIfNull(
7335 Send node, 4837 Send node, Element element, Node index, Node rhs, A arg) {
7336 Element element,
7337 Node index,
7338 Node rhs,
7339 A arg) {
7340 apply(index, arg); 4838 apply(index, arg);
7341 apply(rhs, arg); 4839 apply(rhs, arg);
7342 return null; 4840 return null;
7343 } 4841 }
7344 4842
7345 @override 4843 @override
7346 R errorInvalidIndexSetIfNull( 4844 R errorInvalidIndexSetIfNull(
7347 SendSet node, 4845 SendSet node, ErroneousElement error, Node index, Node rhs, A arg) {
7348 ErroneousElement error,
7349 Node index,
7350 Node rhs,
7351 A arg) {
7352 apply(index, arg); 4846 apply(index, arg);
7353 apply(rhs, arg); 4847 apply(rhs, arg);
7354 return null; 4848 return null;
7355 } 4849 }
7356 } 4850 }
7357 4851
7358 /// [SemanticDeclarationVisitor] that visits subnodes. 4852 /// [SemanticDeclarationVisitor] that visits subnodes.
7359 class TraversalDeclarationMixin<R, A> 4853 class TraversalDeclarationMixin<R, A>
7360 implements SemanticDeclarationVisitor<R, A> { 4854 implements SemanticDeclarationVisitor<R, A> {
7361 @override 4855 @override
7362 R apply(Node node, A arg) { 4856 R apply(Node node, A arg) {
7363 throw new UnimplementedError("TraversalMixin.apply unimplemented"); 4857 throw new UnimplementedError("TraversalMixin.apply unimplemented");
7364 } 4858 }
7365 4859
7366 @override 4860 @override
7367 applyInitializers(FunctionExpression constructor, A arg) { 4861 applyInitializers(FunctionExpression constructor, A arg) {
7368 throw new UnimplementedError( 4862 throw new UnimplementedError(
7369 "TraversalMixin.applyInitializers unimplemented"); 4863 "TraversalMixin.applyInitializers unimplemented");
7370 } 4864 }
7371 4865
7372 @override 4866 @override
7373 applyParameters(NodeList parameters, A arg) { 4867 applyParameters(NodeList parameters, A arg) {
7374 throw new UnimplementedError( 4868 throw new UnimplementedError(
7375 "TraversalMixin.applyParameters unimplemented"); 4869 "TraversalMixin.applyParameters unimplemented");
7376 } 4870 }
7377 4871
7378 @override 4872 @override
7379 R visitAbstractMethodDeclaration( 4873 R visitAbstractMethodDeclaration(FunctionExpression node,
7380 FunctionExpression node, 4874 MethodElement method, NodeList parameters, A arg) {
7381 MethodElement method,
7382 NodeList parameters,
7383 A arg) {
7384 applyParameters(parameters, arg); 4875 applyParameters(parameters, arg);
7385 return null; 4876 return null;
7386 } 4877 }
7387 4878
7388 @override 4879 @override
7389 R visitClosureDeclaration( 4880 R visitClosureDeclaration(FunctionExpression node,
7390 FunctionExpression node, 4881 LocalFunctionElement function, NodeList parameters, Node body, A arg) {
7391 LocalFunctionElement function,
7392 NodeList parameters,
7393 Node body,
7394 A arg) {
7395 applyParameters(parameters, arg); 4882 applyParameters(parameters, arg);
7396 apply(body, arg); 4883 apply(body, arg);
7397 return null; 4884 return null;
7398 } 4885 }
7399 4886
7400 @override 4887 @override
7401 R visitFactoryConstructorDeclaration( 4888 R visitFactoryConstructorDeclaration(FunctionExpression node,
7402 FunctionExpression node, 4889 ConstructorElement constructor, NodeList parameters, Node body, A arg) {
7403 ConstructorElement constructor,
7404 NodeList parameters,
7405 Node body,
7406 A arg) {
7407 applyParameters(parameters, arg); 4890 applyParameters(parameters, arg);
7408 apply(body, arg); 4891 apply(body, arg);
7409 return null; 4892 return null;
7410 } 4893 }
7411 4894
7412 @override 4895 @override
7413 R visitFieldInitializer( 4896 R visitFieldInitializer(
7414 SendSet node, 4897 SendSet node, FieldElement field, Node initializer, A arg) {
7415 FieldElement field,
7416 Node initializer,
7417 A arg) {
7418 apply(initializer, arg); 4898 apply(initializer, arg);
7419 return null; 4899 return null;
7420 } 4900 }
7421 4901
7422 @override 4902 @override
7423 R visitGenerativeConstructorDeclaration( 4903 R visitGenerativeConstructorDeclaration(
7424 FunctionExpression node, 4904 FunctionExpression node,
7425 ConstructorElement constructor, 4905 ConstructorElement constructor,
7426 NodeList parameters, 4906 NodeList parameters,
7427 NodeList initializers, 4907 NodeList initializers,
7428 Node body, 4908 Node body,
7429 A arg) { 4909 A arg) {
7430 applyParameters(parameters, arg); 4910 applyParameters(parameters, arg);
7431 applyInitializers(node, arg); 4911 applyInitializers(node, arg);
7432 apply(body, arg); 4912 apply(body, arg);
7433 return null; 4913 return null;
7434 } 4914 }
7435 4915
7436 @override 4916 @override
7437 R visitInstanceMethodDeclaration( 4917 R visitInstanceMethodDeclaration(FunctionExpression node,
7438 FunctionExpression node, 4918 MethodElement method, NodeList parameters, Node body, A arg) {
7439 MethodElement method,
7440 NodeList parameters,
7441 Node body,
7442 A arg) {
7443 applyParameters(parameters, arg); 4919 applyParameters(parameters, arg);
7444 apply(body, arg); 4920 apply(body, arg);
7445 return null; 4921 return null;
7446 } 4922 }
7447 4923
7448 @override 4924 @override
7449 R visitLocalFunctionDeclaration( 4925 R visitLocalFunctionDeclaration(FunctionExpression node,
7450 FunctionExpression node, 4926 LocalFunctionElement function, NodeList parameters, Node body, A arg) {
7451 LocalFunctionElement function,
7452 NodeList parameters,
7453 Node body,
7454 A arg) {
7455 applyParameters(parameters, arg); 4927 applyParameters(parameters, arg);
7456 apply(body, arg); 4928 apply(body, arg);
7457 return null; 4929 return null;
7458 } 4930 }
7459 4931
7460 @override 4932 @override
7461 R visitRedirectingFactoryConstructorDeclaration( 4933 R visitRedirectingFactoryConstructorDeclaration(
7462 FunctionExpression node, 4934 FunctionExpression node,
7463 ConstructorElement constructor, 4935 ConstructorElement constructor,
7464 NodeList parameters, 4936 NodeList parameters,
(...skipping 10 matching lines...) Expand all
7475 ConstructorElement constructor, 4947 ConstructorElement constructor,
7476 NodeList parameters, 4948 NodeList parameters,
7477 NodeList initializers, 4949 NodeList initializers,
7478 A arg) { 4950 A arg) {
7479 applyParameters(parameters, arg); 4951 applyParameters(parameters, arg);
7480 applyInitializers(node, arg); 4952 applyInitializers(node, arg);
7481 return null; 4953 return null;
7482 } 4954 }
7483 4955
7484 @override 4956 @override
7485 R visitStaticFunctionDeclaration( 4957 R visitStaticFunctionDeclaration(FunctionExpression node,
7486 FunctionExpression node, 4958 MethodElement function, NodeList parameters, Node body, A arg) {
7487 MethodElement function,
7488 NodeList parameters,
7489 Node body,
7490 A arg) {
7491 applyParameters(parameters, arg); 4959 applyParameters(parameters, arg);
7492 apply(body, arg); 4960 apply(body, arg);
7493 return null; 4961 return null;
7494 } 4962 }
7495 4963
7496 @override 4964 @override
7497 R visitSuperConstructorInvoke( 4965 R visitSuperConstructorInvoke(
7498 Send node, 4966 Send node,
7499 ConstructorElement superConstructor, 4967 ConstructorElement superConstructor,
7500 InterfaceType type, 4968 InterfaceType type,
7501 NodeList arguments, 4969 NodeList arguments,
7502 CallStructure callStructure, 4970 CallStructure callStructure,
7503 A arg) { 4971 A arg) {
7504 apply(arguments, arg); 4972 apply(arguments, arg);
7505 return null; 4973 return null;
7506 } 4974 }
7507 4975
7508 @override 4976 @override
7509 R visitImplicitSuperConstructorInvoke( 4977 R visitImplicitSuperConstructorInvoke(FunctionExpression node,
7510 FunctionExpression node, 4978 ConstructorElement superConstructor, InterfaceType type, A arg) {
7511 ConstructorElement superConstructor,
7512 InterfaceType type,
7513 A arg) {
7514 return null; 4979 return null;
7515 } 4980 }
7516 4981
7517 @override 4982 @override
7518 R visitThisConstructorInvoke( 4983 R visitThisConstructorInvoke(Send node, ConstructorElement thisConstructor,
7519 Send node, 4984 NodeList arguments, CallStructure callStructure, A arg) {
7520 ConstructorElement thisConstructor,
7521 NodeList arguments,
7522 CallStructure callStructure,
7523 A arg) {
7524 apply(arguments, arg); 4985 apply(arguments, arg);
7525 return null; 4986 return null;
7526 } 4987 }
7527 4988
7528 @override 4989 @override
7529 R visitTopLevelFunctionDeclaration( 4990 R visitTopLevelFunctionDeclaration(FunctionExpression node,
7530 FunctionExpression node, 4991 MethodElement function, NodeList parameters, Node body, A arg) {
7531 MethodElement function,
7532 NodeList parameters,
7533 Node body,
7534 A arg) {
7535 applyParameters(parameters, arg); 4992 applyParameters(parameters, arg);
7536 apply(body, arg); 4993 apply(body, arg);
7537 return null; 4994 return null;
7538 } 4995 }
7539 4996
7540 @override 4997 @override
7541 R errorUnresolvedFieldInitializer( 4998 R errorUnresolvedFieldInitializer(
7542 SendSet node, 4999 SendSet node, Element element, Node initializer, A arg) {
7543 Element element,
7544 Node initializer,
7545 A arg) {
7546 apply(initializer, arg); 5000 apply(initializer, arg);
7547 return null; 5001 return null;
7548 } 5002 }
7549 5003
7550 @override 5004 @override
7551 R errorUnresolvedSuperConstructorInvoke( 5005 R errorUnresolvedSuperConstructorInvoke(Send node, Element element,
7552 Send node, 5006 NodeList arguments, Selector selector, A arg) {
7553 Element element,
7554 NodeList arguments,
7555 Selector selector,
7556 A arg) {
7557 apply(arguments, arg); 5007 apply(arguments, arg);
7558 return null; 5008 return null;
7559 } 5009 }
7560 5010
7561 @override 5011 @override
7562 R errorUnresolvedThisConstructorInvoke( 5012 R errorUnresolvedThisConstructorInvoke(Send node, Element element,
7563 Send node, 5013 NodeList arguments, Selector selector, A arg) {
7564 Element element,
7565 NodeList arguments,
7566 Selector selector,
7567 A arg) {
7568 apply(arguments, arg); 5014 apply(arguments, arg);
7569 return null; 5015 return null;
7570 } 5016 }
7571 5017
7572 @override 5018 @override
7573 R visitLocalVariableDeclaration( 5019 R visitLocalVariableDeclaration(VariableDefinitions node, Node definition,
7574 VariableDefinitions node, 5020 LocalVariableElement variable, Node initializer, A arg) {
7575 Node definition,
7576 LocalVariableElement variable,
7577 Node initializer,
7578 A arg) {
7579 if (initializer != null) { 5021 if (initializer != null) {
7580 apply(initializer, arg); 5022 apply(initializer, arg);
7581 } 5023 }
7582 return null; 5024 return null;
7583 } 5025 }
7584 5026
7585 @override 5027 @override
7586 R visitOptionalParameterDeclaration( 5028 R visitOptionalParameterDeclaration(
7587 VariableDefinitions node, 5029 VariableDefinitions node,
7588 Node definition, 5030 Node definition,
7589 ParameterElement parameter, 5031 ParameterElement parameter,
7590 ConstantExpression defaultValue, 5032 ConstantExpression defaultValue,
7591 int index, 5033 int index,
7592 A arg) { 5034 A arg) {
7593 return null; 5035 return null;
7594 } 5036 }
7595 5037
7596 @override 5038 @override
7597 R visitParameterDeclaration( 5039 R visitParameterDeclaration(VariableDefinitions node, Node definition,
7598 VariableDefinitions node, 5040 ParameterElement parameter, int index, A arg) {
7599 Node definition,
7600 ParameterElement parameter,
7601 int index,
7602 A arg) {
7603 return null; 5041 return null;
7604 } 5042 }
7605 5043
7606 @override 5044 @override
7607 R visitInitializingFormalDeclaration( 5045 R visitInitializingFormalDeclaration(
7608 VariableDefinitions node, 5046 VariableDefinitions node,
7609 Node definition, 5047 Node definition,
7610 InitializingFormalElement initializingFormal, 5048 InitializingFormalElement initializingFormal,
7611 int index, 5049 int index,
7612 A arg) { 5050 A arg) {
7613 return null; 5051 return null;
7614 } 5052 }
7615 5053
7616 @override 5054 @override
7617 R visitLocalConstantDeclaration( 5055 R visitLocalConstantDeclaration(VariableDefinitions node, Node definition,
7618 VariableDefinitions node, 5056 LocalVariableElement variable, ConstantExpression constant, A arg) {
7619 Node definition,
7620 LocalVariableElement variable,
7621 ConstantExpression constant,
7622 A arg) {
7623 return null; 5057 return null;
7624 } 5058 }
7625 5059
7626 @override 5060 @override
7627 R visitNamedInitializingFormalDeclaration( 5061 R visitNamedInitializingFormalDeclaration(
7628 VariableDefinitions node, 5062 VariableDefinitions node,
7629 Node definition, 5063 Node definition,
7630 InitializingFormalElement initializingFormal, 5064 InitializingFormalElement initializingFormal,
7631 ConstantExpression defaultValue, 5065 ConstantExpression defaultValue,
7632 A arg) { 5066 A arg) {
7633 return null; 5067 return null;
7634 } 5068 }
7635 5069
7636 @override 5070 @override
7637 R visitNamedParameterDeclaration( 5071 R visitNamedParameterDeclaration(VariableDefinitions node, Node definition,
7638 VariableDefinitions node, 5072 ParameterElement parameter, ConstantExpression defaultValue, A arg) {
7639 Node definition,
7640 ParameterElement parameter,
7641 ConstantExpression defaultValue,
7642 A arg) {
7643 return null; 5073 return null;
7644 } 5074 }
7645 5075
7646 @override 5076 @override
7647 R visitOptionalInitializingFormalDeclaration( 5077 R visitOptionalInitializingFormalDeclaration(
7648 VariableDefinitions node, 5078 VariableDefinitions node,
7649 Node definition, 5079 Node definition,
7650 InitializingFormalElement initializingFormal, 5080 InitializingFormalElement initializingFormal,
7651 ConstantExpression defaultValue, 5081 ConstantExpression defaultValue,
7652 int index, 5082 int index,
7653 A arg) { 5083 A arg) {
7654 return null; 5084 return null;
7655 } 5085 }
7656 5086
7657 @override 5087 @override
7658 R visitInstanceFieldDeclaration( 5088 R visitInstanceFieldDeclaration(VariableDefinitions node, Node definition,
7659 VariableDefinitions node, 5089 FieldElement field, Node initializer, A arg) {
7660 Node definition,
7661 FieldElement field,
7662 Node initializer,
7663 A arg) {
7664 if (initializer != null) { 5090 if (initializer != null) {
7665 apply(initializer, arg); 5091 apply(initializer, arg);
7666 } 5092 }
7667 return null; 5093 return null;
7668 } 5094 }
7669 5095
7670 @override 5096 @override
7671 R visitStaticConstantDeclaration( 5097 R visitStaticConstantDeclaration(VariableDefinitions node, Node definition,
7672 VariableDefinitions node, 5098 FieldElement field, ConstantExpression constant, A arg) {
7673 Node definition,
7674 FieldElement field,
7675 ConstantExpression constant,
7676 A arg) {
7677 return null; 5099 return null;
7678 } 5100 }
7679 5101
7680 @override 5102 @override
7681 R visitStaticFieldDeclaration( 5103 R visitStaticFieldDeclaration(VariableDefinitions node, Node definition,
7682 VariableDefinitions node, 5104 FieldElement field, Node initializer, A arg) {
7683 Node definition,
7684 FieldElement field,
7685 Node initializer,
7686 A arg) {
7687 if (initializer != null) { 5105 if (initializer != null) {
7688 apply(initializer, arg); 5106 apply(initializer, arg);
7689 } 5107 }
7690 return null; 5108 return null;
7691 } 5109 }
7692 5110
7693 @override 5111 @override
7694 R visitTopLevelConstantDeclaration( 5112 R visitTopLevelConstantDeclaration(VariableDefinitions node, Node definition,
7695 VariableDefinitions node, 5113 FieldElement field, ConstantExpression constant, A arg) {
7696 Node definition,
7697 FieldElement field,
7698 ConstantExpression constant,
7699 A arg) {
7700 return null; 5114 return null;
7701 } 5115 }
7702 5116
7703 @override 5117 @override
7704 R visitTopLevelFieldDeclaration( 5118 R visitTopLevelFieldDeclaration(VariableDefinitions node, Node definition,
7705 VariableDefinitions node, 5119 FieldElement field, Node initializer, A arg) {
7706 Node definition,
7707 FieldElement field,
7708 Node initializer,
7709 A arg) {
7710 if (initializer != null) { 5120 if (initializer != null) {
7711 apply(initializer, arg); 5121 apply(initializer, arg);
7712 } 5122 }
7713 return null; 5123 return null;
7714 } 5124 }
7715 5125
7716 @override 5126 @override
7717 R visitAbstractGetterDeclaration( 5127 R visitAbstractGetterDeclaration(
7718 FunctionExpression node, 5128 FunctionExpression node, MethodElement getter, A arg) {
7719 MethodElement getter,
7720 A arg) {
7721 return null; 5129 return null;
7722 } 5130 }
7723 5131
7724 @override 5132 @override
7725 R visitAbstractSetterDeclaration( 5133 R visitAbstractSetterDeclaration(FunctionExpression node,
7726 FunctionExpression node, 5134 MethodElement setter, NodeList parameters, A arg) {
7727 MethodElement setter,
7728 NodeList parameters,
7729 A arg) {
7730 applyParameters(parameters, arg); 5135 applyParameters(parameters, arg);
7731 return null; 5136 return null;
7732 } 5137 }
7733 5138
7734 @override 5139 @override
7735 R visitInstanceGetterDeclaration( 5140 R visitInstanceGetterDeclaration(
7736 FunctionExpression node, 5141 FunctionExpression node, MethodElement getter, Node body, A arg) {
7737 MethodElement getter,
7738 Node body,
7739 A arg) {
7740 apply(body, arg); 5142 apply(body, arg);
7741 return null; 5143 return null;
7742 } 5144 }
7743 5145
7744 @override 5146 @override
7745 R visitInstanceSetterDeclaration( 5147 R visitInstanceSetterDeclaration(FunctionExpression node,
7746 FunctionExpression node, 5148 MethodElement setter, NodeList parameters, Node body, A arg) {
7747 MethodElement setter,
7748 NodeList parameters,
7749 Node body,
7750 A arg) {
7751 applyParameters(parameters, arg); 5149 applyParameters(parameters, arg);
7752 apply(body, arg); 5150 apply(body, arg);
7753 return null; 5151 return null;
7754 } 5152 }
7755 5153
7756 @override 5154 @override
7757 R visitStaticGetterDeclaration( 5155 R visitStaticGetterDeclaration(
7758 FunctionExpression node, 5156 FunctionExpression node, MethodElement getter, Node body, A arg) {
7759 MethodElement getter,
7760 Node body,
7761 A arg) {
7762 apply(body, arg); 5157 apply(body, arg);
7763 return null; 5158 return null;
7764 } 5159 }
7765 5160
7766 @override 5161 @override
7767 R visitStaticSetterDeclaration( 5162 R visitStaticSetterDeclaration(FunctionExpression node, MethodElement setter,
7768 FunctionExpression node, 5163 NodeList parameters, Node body, A arg) {
7769 MethodElement setter,
7770 NodeList parameters,
7771 Node body,
7772 A arg) {
7773 applyParameters(parameters, arg); 5164 applyParameters(parameters, arg);
7774 apply(body, arg); 5165 apply(body, arg);
7775 return null; 5166 return null;
7776 } 5167 }
7777 5168
7778 @override 5169 @override
7779 R visitTopLevelGetterDeclaration( 5170 R visitTopLevelGetterDeclaration(
7780 FunctionExpression node, 5171 FunctionExpression node, MethodElement getter, Node body, A arg) {
7781 MethodElement getter,
7782 Node body,
7783 A arg) {
7784 apply(body, arg); 5172 apply(body, arg);
7785 return null; 5173 return null;
7786 } 5174 }
7787 5175
7788 @override 5176 @override
7789 R visitTopLevelSetterDeclaration( 5177 R visitTopLevelSetterDeclaration(FunctionExpression node,
7790 FunctionExpression node, 5178 MethodElement setter, NodeList parameters, Node body, A arg) {
7791 MethodElement setter,
7792 NodeList parameters,
7793 Node body,
7794 A arg) {
7795 applyParameters(parameters, arg); 5179 applyParameters(parameters, arg);
7796 apply(body, arg); 5180 apply(body, arg);
7797 return null; 5181 return null;
7798 } 5182 }
7799 } 5183 }
7800 5184
7801 /// AST visitor that visits all normal [Send] and [SendSet] nodes using the 5185 /// AST visitor that visits all normal [Send] and [SendSet] nodes using the
7802 /// [SemanticVisitor]. 5186 /// [SemanticVisitor].
7803 class TraversalVisitor<R, A> extends SemanticVisitor<R, A> 5187 class TraversalVisitor<R, A> extends SemanticVisitor<R, A>
7804 with TraversalSendMixin<R, A>, 5188 with TraversalSendMixin<R, A>, TraversalDeclarationMixin<R, A> {
7805 TraversalDeclarationMixin<R, A> {
7806 TraversalVisitor(TreeElements elements) : super(elements); 5189 TraversalVisitor(TreeElements elements) : super(elements);
7807 5190
7808 SemanticSendVisitor<R, A> get sendVisitor => this; 5191 SemanticSendVisitor<R, A> get sendVisitor => this;
7809 5192
7810 SemanticDeclarationVisitor<R, A> get declVisitor => this; 5193 SemanticDeclarationVisitor<R, A> get declVisitor => this;
7811 5194
7812 R apply(Node node, A arg) { 5195 R apply(Node node, A arg) {
7813 node.accept(this); 5196 node.accept(this);
7814 return null; 5197 return null;
7815 } 5198 }
(...skipping 26 matching lines...) Expand all
7842 } 5225 }
7843 } 5226 }
7844 5227
7845 /// Mixin that groups all non-compound `visitStaticX` and `visitTopLevelX` 5228 /// Mixin that groups all non-compound `visitStaticX` and `visitTopLevelX`
7846 /// method by delegating calls to `handleStaticX` methods. 5229 /// method by delegating calls to `handleStaticX` methods.
7847 /// 5230 ///
7848 /// This mixin is useful for the cases where both top level members and static 5231 /// This mixin is useful for the cases where both top level members and static
7849 /// class members are handled uniformly. 5232 /// class members are handled uniformly.
7850 abstract class BaseImplementationOfStaticsMixin<R, A> 5233 abstract class BaseImplementationOfStaticsMixin<R, A>
7851 implements SemanticSendVisitor<R, A> { 5234 implements SemanticSendVisitor<R, A> {
7852 R handleStaticFieldGet( 5235 R handleStaticFieldGet(Send node, FieldElement field, A arg);
7853 Send node, 5236
7854 FieldElement field, 5237 R handleStaticFieldInvoke(Send node, FieldElement field, NodeList arguments,
7855 A arg); 5238 CallStructure callStructure, A arg);
7856 5239
7857 R handleStaticFieldInvoke( 5240 R handleStaticFieldSet(SendSet node, FieldElement field, Node rhs, A arg);
7858 Send node, 5241
7859 FieldElement field, 5242 R handleStaticFunctionGet(Send node, MethodElement function, A arg);
7860 NodeList arguments, 5243
7861 CallStructure callStructure, 5244 R handleStaticFunctionInvoke(Send node, MethodElement function,
7862 A arg); 5245 NodeList arguments, CallStructure callStructure, A arg);
7863 5246
7864 R handleStaticFieldSet( 5247 R handleStaticFunctionIncompatibleInvoke(Send node, MethodElement function,
7865 SendSet node, 5248 NodeList arguments, CallStructure callStructure, A arg);
7866 FieldElement field, 5249
7867 Node rhs, 5250 R handleStaticGetterGet(Send node, FunctionElement getter, A arg);
7868 A arg); 5251
7869 5252 R handleStaticGetterSet(Send node, FunctionElement getter, Node rhs, A arg);
7870 R handleStaticFunctionGet( 5253
7871 Send node, 5254 R handleStaticGetterInvoke(Send node, FunctionElement getter,
7872 MethodElement function, 5255 NodeList arguments, CallStructure callStructure, A arg);
7873 A arg); 5256
7874 5257 R handleStaticSetterGet(SendSet node, FunctionElement setter, A arg);
7875 R handleStaticFunctionInvoke(
7876 Send node,
7877 MethodElement function,
7878 NodeList arguments,
7879 CallStructure callStructure,
7880 A arg);
7881
7882 R handleStaticFunctionIncompatibleInvoke(
7883 Send node,
7884 MethodElement function,
7885 NodeList arguments,
7886 CallStructure callStructure,
7887 A arg);
7888
7889 R handleStaticGetterGet(
7890 Send node,
7891 FunctionElement getter,
7892 A arg);
7893
7894 R handleStaticGetterSet(
7895 Send node,
7896 FunctionElement getter,
7897 Node rhs,
7898 A arg);
7899
7900 R handleStaticGetterInvoke(
7901 Send node,
7902 FunctionElement getter,
7903 NodeList arguments,
7904 CallStructure callStructure,
7905 A arg);
7906
7907 R handleStaticSetterGet(
7908 SendSet node,
7909 FunctionElement setter,
7910 A arg);
7911 5258
7912 R handleStaticSetterSet( 5259 R handleStaticSetterSet(
7913 SendSet node, 5260 SendSet node, FunctionElement setter, Node rhs, A arg);
7914 FunctionElement setter, 5261
7915 Node rhs, 5262 R handleStaticSetterInvoke(Send node, FunctionElement setter,
7916 A arg); 5263 NodeList arguments, CallStructure callStructure, A arg);
7917
7918 R handleStaticSetterInvoke(
7919 Send node,
7920 FunctionElement setter,
7921 NodeList arguments,
7922 CallStructure callStructure,
7923 A arg);
7924 5264
7925 R handleFinalStaticFieldSet( 5265 R handleFinalStaticFieldSet(
7926 SendSet node, 5266 SendSet node, FieldElement field, Node rhs, A arg);
7927 FieldElement field,
7928 Node rhs,
7929 A arg);
7930 5267
7931 R handleStaticFunctionSet( 5268 R handleStaticFunctionSet(
7932 SendSet node, 5269 SendSet node, MethodElement function, Node rhs, A arg);
7933 MethodElement function, 5270
7934 Node rhs, 5271 @override
7935 A arg); 5272 R visitStaticFieldGet(Send node, FieldElement field, A arg) {
7936
7937 @override
7938 R visitStaticFieldGet(
7939 Send node,
7940 FieldElement field,
7941 A arg) {
7942 return handleStaticFieldGet(node, field, arg); 5273 return handleStaticFieldGet(node, field, arg);
7943 } 5274 }
7944 5275
7945 @override 5276 @override
7946 R visitStaticFieldInvoke( 5277 R visitStaticFieldInvoke(Send node, FieldElement field, NodeList arguments,
7947 Send node, 5278 CallStructure callStructure, A arg) {
7948 FieldElement field,
7949 NodeList arguments,
7950 CallStructure callStructure,
7951 A arg) {
7952 return handleStaticFieldInvoke(node, field, arguments, callStructure, arg); 5279 return handleStaticFieldInvoke(node, field, arguments, callStructure, arg);
7953 } 5280 }
7954 5281
7955 @override 5282 @override
7956 R visitStaticFieldSet( 5283 R visitStaticFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
7957 SendSet node,
7958 FieldElement field,
7959 Node rhs,
7960 A arg) {
7961 return handleStaticFieldSet(node, field, rhs, arg); 5284 return handleStaticFieldSet(node, field, rhs, arg);
7962 } 5285 }
7963 5286
7964 @override 5287 @override
7965 R visitStaticFunctionGet( 5288 R visitStaticFunctionGet(Send node, MethodElement function, A arg) {
7966 Send node,
7967 MethodElement function,
7968 A arg) {
7969 return handleStaticFunctionGet(node, function, arg); 5289 return handleStaticFunctionGet(node, function, arg);
7970 } 5290 }
7971 5291
7972 @override 5292 @override
7973 R visitStaticFunctionInvoke( 5293 R visitStaticFunctionInvoke(Send node, MethodElement function,
7974 Send node, 5294 NodeList arguments, CallStructure callStructure, A arg) {
7975 MethodElement function,
7976 NodeList arguments,
7977 CallStructure callStructure,
7978 A arg) {
7979 return handleStaticFunctionInvoke( 5295 return handleStaticFunctionInvoke(
7980 node, function, arguments, callStructure, arg); 5296 node, function, arguments, callStructure, arg);
7981 } 5297 }
7982 5298
7983 @override 5299 @override
7984 R visitStaticFunctionIncompatibleInvoke( 5300 R visitStaticFunctionIncompatibleInvoke(Send node, MethodElement function,
7985 Send node, 5301 NodeList arguments, CallStructure callStructure, A arg) {
7986 MethodElement function,
7987 NodeList arguments,
7988 CallStructure callStructure,
7989 A arg) {
7990 return handleStaticFunctionIncompatibleInvoke( 5302 return handleStaticFunctionIncompatibleInvoke(
7991 node, function, arguments, callStructure, arg); 5303 node, function, arguments, callStructure, arg);
7992 } 5304 }
7993 5305
7994 @override 5306 @override
7995 R visitStaticGetterGet( 5307 R visitStaticGetterGet(Send node, FunctionElement getter, A arg) {
7996 Send node,
7997 FunctionElement getter,
7998 A arg) {
7999 return handleStaticGetterGet(node, getter, arg); 5308 return handleStaticGetterGet(node, getter, arg);
8000 } 5309 }
8001 5310
8002 @override 5311 @override
8003 R visitStaticGetterInvoke( 5312 R visitStaticGetterInvoke(Send node, FunctionElement getter,
8004 Send node, 5313 NodeList arguments, CallStructure callStructure, A arg) {
8005 FunctionElement getter,
8006 NodeList arguments,
8007 CallStructure callStructure,
8008 A arg) {
8009 return handleStaticGetterInvoke( 5314 return handleStaticGetterInvoke(
8010 node, getter, arguments, callStructure, arg); 5315 node, getter, arguments, callStructure, arg);
8011 } 5316 }
8012 5317
8013 @override 5318 @override
8014 R visitStaticSetterSet( 5319 R visitStaticSetterSet(
8015 SendSet node, 5320 SendSet node, FunctionElement setter, Node rhs, A arg) {
8016 FunctionElement setter,
8017 Node rhs,
8018 A arg) {
8019 return handleStaticSetterSet(node, setter, rhs, arg); 5321 return handleStaticSetterSet(node, setter, rhs, arg);
8020 } 5322 }
8021 5323
8022 @override 5324 @override
8023 R visitTopLevelFieldGet( 5325 R visitTopLevelFieldGet(Send node, FieldElement field, A arg) {
8024 Send node,
8025 FieldElement field,
8026 A arg) {
8027 return handleStaticFieldGet(node, field, arg); 5326 return handleStaticFieldGet(node, field, arg);
8028 } 5327 }
8029 5328
8030 @override 5329 @override
8031 R visitTopLevelFieldInvoke( 5330 R visitTopLevelFieldInvoke(Send node, FieldElement field, NodeList arguments,
8032 Send node, 5331 CallStructure callStructure, A arg) {
8033 FieldElement field,
8034 NodeList arguments,
8035 CallStructure callStructure,
8036 A arg) {
8037 return handleStaticFieldInvoke(node, field, arguments, callStructure, arg); 5332 return handleStaticFieldInvoke(node, field, arguments, callStructure, arg);
8038 } 5333 }
8039 5334
8040 @override 5335 @override
8041 R visitTopLevelFieldSet( 5336 R visitTopLevelFieldSet(SendSet node, FieldElement field, Node rhs, A arg) {
8042 SendSet node,
8043 FieldElement field,
8044 Node rhs,
8045 A arg) {
8046 return handleStaticFieldSet(node, field, rhs, arg); 5337 return handleStaticFieldSet(node, field, rhs, arg);
8047 } 5338 }
8048 5339
8049 @override 5340 @override
8050 R visitTopLevelFunctionGet( 5341 R visitTopLevelFunctionGet(Send node, MethodElement function, A arg) {
8051 Send node,
8052 MethodElement function,
8053 A arg) {
8054 return handleStaticFunctionGet(node, function, arg); 5342 return handleStaticFunctionGet(node, function, arg);
8055 } 5343 }
8056 5344
8057 @override 5345 @override
8058 R visitTopLevelFunctionInvoke( 5346 R visitTopLevelFunctionInvoke(Send node, MethodElement function,
8059 Send node, 5347 NodeList arguments, CallStructure callStructure, A arg) {
8060 MethodElement function,
8061 NodeList arguments,
8062 CallStructure callStructure,
8063 A arg) {
8064 return handleStaticFunctionInvoke( 5348 return handleStaticFunctionInvoke(
8065 node, function, arguments, callStructure, arg); 5349 node, function, arguments, callStructure, arg);
8066 } 5350 }
8067 5351
8068 @override 5352 @override
8069 R visitTopLevelFunctionIncompatibleInvoke( 5353 R visitTopLevelFunctionIncompatibleInvoke(Send node, MethodElement function,
8070 Send node, 5354 NodeList arguments, CallStructure callStructure, A arg) {
8071 MethodElement function,
8072 NodeList arguments,
8073 CallStructure callStructure,
8074 A arg) {
8075 return handleStaticFunctionIncompatibleInvoke( 5355 return handleStaticFunctionIncompatibleInvoke(
8076 node, function, arguments, callStructure, arg); 5356 node, function, arguments, callStructure, arg);
8077 } 5357 }
8078 5358
8079 @override 5359 @override
8080 R visitTopLevelGetterGet( 5360 R visitTopLevelGetterGet(Send node, FunctionElement getter, A arg) {
8081 Send node,
8082 FunctionElement getter,
8083 A arg) {
8084 return handleStaticGetterGet(node, getter, arg); 5361 return handleStaticGetterGet(node, getter, arg);
8085 } 5362 }
8086 5363
8087 @override 5364 @override
8088 R visitTopLevelGetterSet( 5365 R visitTopLevelGetterSet(
8089 SendSet node, 5366 SendSet node, FunctionElement getter, Node rhs, A arg) {
8090 FunctionElement getter,
8091 Node rhs,
8092 A arg) {
8093 return handleStaticGetterSet(node, getter, rhs, arg); 5367 return handleStaticGetterSet(node, getter, rhs, arg);
8094 } 5368 }
8095 5369
8096 @override 5370 @override
8097 R visitTopLevelGetterInvoke( 5371 R visitTopLevelGetterInvoke(Send node, FunctionElement getter,
8098 Send node, 5372 NodeList arguments, CallStructure callStructure, A arg) {
8099 FunctionElement getter,
8100 NodeList arguments,
8101 CallStructure callStructure,
8102 A arg) {
8103 return handleStaticGetterInvoke( 5373 return handleStaticGetterInvoke(
8104 node, getter, arguments, callStructure, arg); 5374 node, getter, arguments, callStructure, arg);
8105 } 5375 }
8106 5376
8107 @override 5377 @override
8108 R visitTopLevelSetterSet( 5378 R visitTopLevelSetterSet(
8109 SendSet node, 5379 SendSet node, FunctionElement setter, Node rhs, A arg) {
8110 FunctionElement setter,
8111 Node rhs,
8112 A arg) {
8113 return handleStaticSetterSet(node, setter, rhs, arg); 5380 return handleStaticSetterSet(node, setter, rhs, arg);
8114 } 5381 }
8115 5382
8116 @override 5383 @override
8117 R visitStaticSetterInvoke( 5384 R visitStaticSetterInvoke(Send node, FunctionElement setter,
8118 Send node, 5385 NodeList arguments, CallStructure callStructure, A arg) {
8119 FunctionElement setter,
8120 NodeList arguments,
8121 CallStructure callStructure,
8122 A arg) {
8123 return handleStaticSetterInvoke( 5386 return handleStaticSetterInvoke(
8124 node, setter, arguments, callStructure, arg); 5387 node, setter, arguments, callStructure, arg);
8125 } 5388 }
8126 5389
8127 @override 5390 @override
8128 R visitTopLevelSetterInvoke( 5391 R visitTopLevelSetterInvoke(Send node, FunctionElement setter,
8129 Send node, 5392 NodeList arguments, CallStructure callStructure, A arg) {
8130 FunctionElement setter,
8131 NodeList arguments,
8132 CallStructure callStructure,
8133 A arg) {
8134 return handleStaticSetterInvoke( 5393 return handleStaticSetterInvoke(
8135 node, setter, arguments, callStructure, arg); 5394 node, setter, arguments, callStructure, arg);
8136 } 5395 }
8137 5396
8138 @override 5397 @override
8139 R visitStaticSetterGet( 5398 R visitStaticSetterGet(Send node, FunctionElement setter, A arg) {
8140 Send node,
8141 FunctionElement setter,
8142 A arg) {
8143 return handleStaticSetterGet(node, setter, arg); 5399 return handleStaticSetterGet(node, setter, arg);
8144 } 5400 }
8145 5401
8146 @override 5402 @override
8147 R visitStaticGetterSet( 5403 R visitStaticGetterSet(
8148 SendSet node, 5404 SendSet node, FunctionElement getter, Node rhs, A arg) {
8149 FunctionElement getter,
8150 Node rhs,
8151 A arg) {
8152 return handleStaticGetterSet(node, getter, rhs, arg); 5405 return handleStaticGetterSet(node, getter, rhs, arg);
8153 } 5406 }
8154 5407
8155 @override 5408 @override
8156 R visitTopLevelSetterGet( 5409 R visitTopLevelSetterGet(Send node, FunctionElement setter, A arg) {
8157 Send node,
8158 FunctionElement setter,
8159 A arg) {
8160 return handleStaticSetterGet(node, setter, arg); 5410 return handleStaticSetterGet(node, setter, arg);
8161 } 5411 }
8162 5412
8163 @override 5413 @override
8164 R visitFinalStaticFieldSet( 5414 R visitFinalStaticFieldSet(
8165 SendSet node, 5415 SendSet node, FieldElement field, Node rhs, A arg) {
8166 FieldElement field,
8167 Node rhs,
8168 A arg) {
8169 return handleFinalStaticFieldSet(node, field, rhs, arg); 5416 return handleFinalStaticFieldSet(node, field, rhs, arg);
8170 } 5417 }
8171 5418
8172 @override 5419 @override
8173 R visitFinalTopLevelFieldSet( 5420 R visitFinalTopLevelFieldSet(
8174 SendSet node, 5421 SendSet node, FieldElement field, Node rhs, A arg) {
8175 FieldElement field,
8176 Node rhs,
8177 A arg) {
8178 return handleFinalStaticFieldSet(node, field, rhs, arg); 5422 return handleFinalStaticFieldSet(node, field, rhs, arg);
8179 } 5423 }
8180 5424
8181 @override 5425 @override
8182 R visitStaticFunctionSet( 5426 R visitStaticFunctionSet(Send node, MethodElement function, Node rhs, A arg) {
8183 Send node,
8184 MethodElement function,
8185 Node rhs,
8186 A arg) {
8187 return handleStaticFunctionSet(node, function, rhs, arg); 5427 return handleStaticFunctionSet(node, function, rhs, arg);
8188 } 5428 }
8189 5429
8190 @override 5430 @override
8191 R visitTopLevelFunctionSet( 5431 R visitTopLevelFunctionSet(
8192 Send node, 5432 Send node, MethodElement function, Node rhs, A arg) {
8193 MethodElement function,
8194 Node rhs,
8195 A arg) {
8196 return handleStaticFunctionSet(node, function, rhs, arg); 5433 return handleStaticFunctionSet(node, function, rhs, arg);
8197 } 5434 }
8198 } 5435 }
8199 5436
8200 /// Mixin that groups all compounds visitors `visitStaticX` and `visitTopLevelX` 5437 /// Mixin that groups all compounds visitors `visitStaticX` and `visitTopLevelX`
8201 /// method by delegating calls to `handleStaticX` methods. 5438 /// method by delegating calls to `handleStaticX` methods.
8202 /// 5439 ///
8203 /// This mixin is useful for the cases where both top level members and static 5440 /// This mixin is useful for the cases where both top level members and static
8204 /// class members are handled uniformly. 5441 /// class members are handled uniformly.
8205 abstract class BaseImplementationOfStaticCompoundsMixin<R, A> 5442 abstract class BaseImplementationOfStaticCompoundsMixin<R, A>
8206 implements SemanticSendVisitor<R, A> { 5443 implements SemanticSendVisitor<R, A> {
8207 R handleStaticFieldCompound( 5444 R handleStaticFieldCompound(Send node, FieldElement field,
8208 Send node, 5445 AssignmentOperator operator, Node rhs, A arg);
8209 FieldElement field,
8210 AssignmentOperator operator,
8211 Node rhs,
8212 A arg);
8213 5446
8214 R handleStaticFieldPostfixPrefix( 5447 R handleStaticFieldPostfixPrefix(
8215 Send node, 5448 Send node, FieldElement field, IncDecOperator operator, A arg,
8216 FieldElement field, 5449 {bool isPrefix});
8217 IncDecOperator operator, 5450
8218 A arg, 5451 R handleStaticGetterSetterCompound(Send node, FunctionElement getter,
8219 {bool isPrefix}); 5452 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg);
8220 5453
8221 R handleStaticGetterSetterCompound( 5454 R handleStaticGetterSetterPostfixPrefix(Send node, FunctionElement getter,
8222 Send node, 5455 FunctionElement setter, IncDecOperator operator, A arg,
8223 FunctionElement getter, 5456 {bool isPrefix});
8224 FunctionElement setter, 5457
8225 AssignmentOperator operator, 5458 R handleStaticMethodSetterCompound(Send node, FunctionElement method,
8226 Node rhs, 5459 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg);
8227 A arg); 5460
8228 5461 R handleStaticMethodSetterPostfixPrefix(Send node, FunctionElement getter,
8229 R handleStaticGetterSetterPostfixPrefix( 5462 FunctionElement setter, IncDecOperator operator, A arg,
8230 Send node, 5463 {bool isPrefix});
8231 FunctionElement getter, 5464
8232 FunctionElement setter, 5465 R handleFinalStaticFieldCompound(Send node, FieldElement field,
8233 IncDecOperator operator, 5466 AssignmentOperator operator, Node rhs, A arg);
8234 A arg,
8235 {bool isPrefix});
8236
8237 R handleStaticMethodSetterCompound(
8238 Send node,
8239 FunctionElement method,
8240 FunctionElement setter,
8241 AssignmentOperator operator,
8242 Node rhs,
8243 A arg);
8244
8245 R handleStaticMethodSetterPostfixPrefix(
8246 Send node,
8247 FunctionElement getter,
8248 FunctionElement setter,
8249 IncDecOperator operator,
8250 A arg,
8251 {bool isPrefix});
8252
8253 R handleFinalStaticFieldCompound(
8254 Send node,
8255 FieldElement field,
8256 AssignmentOperator operator,
8257 Node rhs,
8258 A arg);
8259 5467
8260 R handleFinalStaticFieldPostfixPrefix( 5468 R handleFinalStaticFieldPostfixPrefix(
8261 Send node, 5469 Send node, FieldElement field, IncDecOperator operator, A arg,
8262 FieldElement field, 5470 {bool isPrefix});
8263 IncDecOperator operator, 5471
8264 A arg, 5472 R handleStaticMethodCompound(Send node, FunctionElement method,
8265 {bool isPrefix}); 5473 AssignmentOperator operator, Node rhs, A arg);
8266
8267 R handleStaticMethodCompound(
8268 Send node,
8269 FunctionElement method,
8270 AssignmentOperator operator,
8271 Node rhs,
8272 A arg);
8273 5474
8274 R handleStaticMethodPostfixPrefix( 5475 R handleStaticMethodPostfixPrefix(
8275 Send node, 5476 Send node, FunctionElement method, IncDecOperator operator, A arg,
8276 FunctionElement method, 5477 {bool isPrefix});
8277 IncDecOperator operator, 5478
8278 A arg, 5479 R handleUnresolvedStaticGetterCompound(Send node, Element element,
8279 {bool isPrefix}); 5480 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg);
8280 5481
8281 R handleUnresolvedStaticGetterCompound( 5482 R handleUnresolvedStaticGetterPostfixPrefix(Send node, Element element,
8282 Send node, 5483 FunctionElement setter, IncDecOperator operator, A arg,
8283 Element element, 5484 {bool isPrefix});
8284 FunctionElement setter, 5485
8285 AssignmentOperator operator, 5486 R handleUnresolvedStaticSetterCompound(Send node, FunctionElement getter,
8286 Node rhs, 5487 Element element, AssignmentOperator operator, Node rhs, A arg);
8287 A arg); 5488
8288 5489 R handleUnresolvedStaticSetterPostfixPrefix(Send node, FunctionElement getter,
8289 R handleUnresolvedStaticGetterPostfixPrefix( 5490 Element element, IncDecOperator operator, A arg,
8290 Send node, 5491 {bool isPrefix});
8291 Element element, 5492
8292 FunctionElement setter, 5493 @override
8293 IncDecOperator operator, 5494 R visitStaticFieldCompound(Send node, FieldElement field,
8294 A arg, 5495 AssignmentOperator operator, Node rhs, A arg) {
8295 {bool isPrefix});
8296
8297 R handleUnresolvedStaticSetterCompound(
8298 Send node,
8299 FunctionElement getter,
8300 Element element,
8301 AssignmentOperator operator,
8302 Node rhs,
8303 A arg);
8304
8305 R handleUnresolvedStaticSetterPostfixPrefix(
8306 Send node,
8307 FunctionElement getter,
8308 Element element,
8309 IncDecOperator operator,
8310 A arg,
8311 {bool isPrefix});
8312
8313 @override
8314 R visitStaticFieldCompound(
8315 Send node,
8316 FieldElement field,
8317 AssignmentOperator operator,
8318 Node rhs,
8319 A arg) {
8320 return handleStaticFieldCompound(node, field, operator, rhs, arg); 5496 return handleStaticFieldCompound(node, field, operator, rhs, arg);
8321 } 5497 }
8322 5498
8323 @override 5499 @override
8324 R visitStaticFieldPostfix( 5500 R visitStaticFieldPostfix(
8325 Send node, 5501 Send node, FieldElement field, IncDecOperator operator, A arg) {
8326 FieldElement field, 5502 return handleStaticFieldPostfixPrefix(node, field, operator, arg,
8327 IncDecOperator operator, 5503 isPrefix: false);
8328 A arg) {
8329 return handleStaticFieldPostfixPrefix(
8330 node, field, operator, arg, isPrefix: false);
8331 } 5504 }
8332 5505
8333 @override 5506 @override
8334 R visitStaticFieldPrefix( 5507 R visitStaticFieldPrefix(
8335 Send node, 5508 Send node, FieldElement field, IncDecOperator operator, A arg) {
8336 FieldElement field, 5509 return handleStaticFieldPostfixPrefix(node, field, operator, arg,
8337 IncDecOperator operator, 5510 isPrefix: true);
8338 A arg) { 5511 }
8339 return handleStaticFieldPostfixPrefix( 5512
8340 node, field, operator, arg, isPrefix: true); 5513 @override
8341 } 5514 R visitStaticGetterSetterCompound(Send node, FunctionElement getter,
8342 5515 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
8343 @override
8344 R visitStaticGetterSetterCompound(
8345 Send node,
8346 FunctionElement getter,
8347 FunctionElement setter,
8348 AssignmentOperator operator,
8349 Node rhs,
8350 A arg) {
8351 return handleStaticGetterSetterCompound( 5516 return handleStaticGetterSetterCompound(
8352 node, getter, setter, operator, rhs, arg); 5517 node, getter, setter, operator, rhs, arg);
8353 } 5518 }
8354 5519
8355 @override 5520 @override
8356 R visitStaticGetterSetterPostfix( 5521 R visitStaticGetterSetterPostfix(Send node, FunctionElement getter,
8357 Send node, 5522 FunctionElement setter, IncDecOperator operator, A arg) {
8358 FunctionElement getter, 5523 return handleStaticGetterSetterPostfixPrefix(
8359 FunctionElement setter, 5524 node, getter, setter, operator, arg,
8360 IncDecOperator operator, 5525 isPrefix: false);
8361 A arg) { 5526 }
8362 return handleStaticGetterSetterPostfixPrefix( 5527
8363 node, getter, setter, operator, arg, isPrefix: false); 5528 @override
8364 } 5529 R visitStaticGetterSetterPrefix(Send node, FunctionElement getter,
8365 5530 FunctionElement setter, IncDecOperator operator, A arg) {
8366 @override 5531 return handleStaticGetterSetterPostfixPrefix(
8367 R visitStaticGetterSetterPrefix( 5532 node, getter, setter, operator, arg,
8368 Send node, 5533 isPrefix: true);
8369 FunctionElement getter, 5534 }
8370 FunctionElement setter, 5535
8371 IncDecOperator operator, 5536 @override
8372 A arg) { 5537 R visitStaticMethodSetterCompound(Send node, FunctionElement method,
8373 return handleStaticGetterSetterPostfixPrefix( 5538 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
8374 node, getter, setter, operator, arg, isPrefix: true);
8375 }
8376
8377 @override
8378 R visitStaticMethodSetterCompound(
8379 Send node,
8380 FunctionElement method,
8381 FunctionElement setter,
8382 AssignmentOperator operator,
8383 Node rhs,
8384 A arg) {
8385 return handleStaticMethodSetterCompound( 5539 return handleStaticMethodSetterCompound(
8386 node, method, setter, operator, rhs, arg); 5540 node, method, setter, operator, rhs, arg);
8387 } 5541 }
8388 5542
8389 @override 5543 @override
8390 R visitStaticMethodSetterPostfix( 5544 R visitStaticMethodSetterPostfix(Send node, FunctionElement getter,
8391 Send node, 5545 FunctionElement setter, IncDecOperator operator, A arg) {
8392 FunctionElement getter, 5546 return handleStaticMethodSetterPostfixPrefix(
8393 FunctionElement setter, 5547 node, getter, setter, operator, arg,
8394 IncDecOperator operator, 5548 isPrefix: false);
8395 A arg) { 5549 }
8396 return handleStaticMethodSetterPostfixPrefix( 5550
8397 node, getter, setter, operator, arg, isPrefix: false); 5551 @override
8398 } 5552 R visitStaticMethodSetterPrefix(Send node, FunctionElement getter,
8399 5553 FunctionElement setter, IncDecOperator operator, A arg) {
8400 @override 5554 return handleStaticMethodSetterPostfixPrefix(
8401 R visitStaticMethodSetterPrefix( 5555 node, getter, setter, operator, arg,
8402 Send node, 5556 isPrefix: true);
8403 FunctionElement getter, 5557 }
8404 FunctionElement setter, 5558
8405 IncDecOperator operator, 5559 @override
8406 A arg) { 5560 R visitTopLevelFieldCompound(Send node, FieldElement field,
8407 return handleStaticMethodSetterPostfixPrefix( 5561 AssignmentOperator operator, Node rhs, A arg) {
8408 node, getter, setter, operator, arg, isPrefix: true);
8409 }
8410
8411 @override
8412 R visitTopLevelFieldCompound(
8413 Send node,
8414 FieldElement field,
8415 AssignmentOperator operator,
8416 Node rhs,
8417 A arg) {
8418 return handleStaticFieldCompound(node, field, operator, rhs, arg); 5562 return handleStaticFieldCompound(node, field, operator, rhs, arg);
8419 } 5563 }
8420 5564
8421 @override 5565 @override
8422 R visitTopLevelFieldPostfix( 5566 R visitTopLevelFieldPostfix(
8423 Send node, 5567 Send node, FieldElement field, IncDecOperator operator, A arg) {
8424 FieldElement field, 5568 return handleStaticFieldPostfixPrefix(node, field, operator, arg,
8425 IncDecOperator operator, 5569 isPrefix: false);
8426 A arg) {
8427 return handleStaticFieldPostfixPrefix(
8428 node, field, operator, arg, isPrefix: false);
8429 } 5570 }
8430 5571
8431 @override 5572 @override
8432 R visitTopLevelFieldPrefix( 5573 R visitTopLevelFieldPrefix(
8433 Send node, 5574 Send node, FieldElement field, IncDecOperator operator, A arg) {
8434 FieldElement field, 5575 return handleStaticFieldPostfixPrefix(node, field, operator, arg,
8435 IncDecOperator operator, 5576 isPrefix: true);
8436 A arg) { 5577 }
8437 return handleStaticFieldPostfixPrefix( 5578
8438 node, field, operator, arg, isPrefix: true); 5579 @override
8439 } 5580 R visitTopLevelGetterSetterCompound(Send node, FunctionElement getter,
8440 5581 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
8441 @override
8442 R visitTopLevelGetterSetterCompound(
8443 Send node,
8444 FunctionElement getter,
8445 FunctionElement setter,
8446 AssignmentOperator operator,
8447 Node rhs,
8448 A arg) {
8449 return handleStaticGetterSetterCompound( 5582 return handleStaticGetterSetterCompound(
8450 node, getter, setter, operator, rhs, arg); 5583 node, getter, setter, operator, rhs, arg);
8451 } 5584 }
8452 5585
8453 @override 5586 @override
8454 R visitTopLevelGetterSetterPostfix( 5587 R visitTopLevelGetterSetterPostfix(Send node, FunctionElement getter,
8455 Send node, 5588 FunctionElement setter, IncDecOperator operator, A arg) {
8456 FunctionElement getter, 5589 return handleStaticGetterSetterPostfixPrefix(
8457 FunctionElement setter, 5590 node, getter, setter, operator, arg,
8458 IncDecOperator operator, 5591 isPrefix: false);
8459 A arg) { 5592 }
8460 return handleStaticGetterSetterPostfixPrefix( 5593
8461 node, getter, setter, operator, arg, isPrefix: false); 5594 @override
8462 } 5595 R visitTopLevelGetterSetterPrefix(Send node, FunctionElement getter,
8463 5596 FunctionElement setter, IncDecOperator operator, A arg) {
8464 @override 5597 return handleStaticGetterSetterPostfixPrefix(
8465 R visitTopLevelGetterSetterPrefix( 5598 node, getter, setter, operator, arg,
8466 Send node, 5599 isPrefix: true);
8467 FunctionElement getter, 5600 }
8468 FunctionElement setter, 5601
8469 IncDecOperator operator, 5602 @override
8470 A arg) { 5603 R visitTopLevelMethodSetterCompound(Send node, FunctionElement method,
8471 return handleStaticGetterSetterPostfixPrefix( 5604 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
8472 node, getter, setter, operator, arg, isPrefix: true);
8473 }
8474
8475 @override
8476 R visitTopLevelMethodSetterCompound(
8477 Send node,
8478 FunctionElement method,
8479 FunctionElement setter,
8480 AssignmentOperator operator,
8481 Node rhs,
8482 A arg) {
8483 return handleStaticMethodSetterCompound( 5605 return handleStaticMethodSetterCompound(
8484 node, method, setter, operator, rhs, arg); 5606 node, method, setter, operator, rhs, arg);
8485 } 5607 }
8486 5608
8487 @override 5609 @override
8488 R visitTopLevelMethodSetterPostfix( 5610 R visitTopLevelMethodSetterPostfix(Send node, FunctionElement method,
8489 Send node, 5611 FunctionElement setter, IncDecOperator operator, A arg) {
8490 FunctionElement method, 5612 return handleStaticMethodSetterPostfixPrefix(
8491 FunctionElement setter, 5613 node, method, setter, operator, arg,
8492 IncDecOperator operator, 5614 isPrefix: false);
8493 A arg) { 5615 }
8494 return handleStaticMethodSetterPostfixPrefix( 5616
8495 node, method, setter, operator, arg, isPrefix: false); 5617 @override
8496 } 5618 R visitTopLevelMethodSetterPrefix(Send node, FunctionElement method,
8497 5619 FunctionElement setter, IncDecOperator operator, A arg) {
8498 @override 5620 return handleStaticMethodSetterPostfixPrefix(
8499 R visitTopLevelMethodSetterPrefix( 5621 node, method, setter, operator, arg,
8500 Send node, 5622 isPrefix: true);
8501 FunctionElement method, 5623 }
8502 FunctionElement setter, 5624
8503 IncDecOperator operator, 5625 @override
8504 A arg) { 5626 R visitFinalStaticFieldCompound(Send node, FieldElement field,
8505 return handleStaticMethodSetterPostfixPrefix( 5627 AssignmentOperator operator, Node rhs, A arg) {
8506 node, method, setter, operator, arg, isPrefix: true); 5628 return handleFinalStaticFieldCompound(node, field, operator, rhs, arg);
8507 }
8508
8509 @override
8510 R visitFinalStaticFieldCompound(
8511 Send node,
8512 FieldElement field,
8513 AssignmentOperator operator,
8514 Node rhs,
8515 A arg) {
8516 return handleFinalStaticFieldCompound(
8517 node, field, operator, rhs, arg);
8518 } 5629 }
8519 5630
8520 @override 5631 @override
8521 R visitFinalStaticFieldPostfix( 5632 R visitFinalStaticFieldPostfix(
8522 Send node, 5633 Send node, FieldElement field, IncDecOperator operator, A arg) {
8523 FieldElement field, 5634 return handleFinalStaticFieldPostfixPrefix(node, field, operator, arg,
8524 IncDecOperator operator, 5635 isPrefix: false);
8525 A arg) {
8526 return handleFinalStaticFieldPostfixPrefix(
8527 node, field, operator, arg, isPrefix: false);
8528 } 5636 }
8529 5637
8530 @override 5638 @override
8531 R visitFinalStaticFieldPrefix( 5639 R visitFinalStaticFieldPrefix(
8532 Send node, 5640 Send node, FieldElement field, IncDecOperator operator, A arg) {
8533 FieldElement field, 5641 return handleFinalStaticFieldPostfixPrefix(node, field, operator, arg,
8534 IncDecOperator operator, 5642 isPrefix: true);
8535 A arg) { 5643 }
8536 return handleFinalStaticFieldPostfixPrefix( 5644
8537 node, field, operator, arg, isPrefix: true); 5645 @override
8538 } 5646 R visitStaticMethodCompound(Send node, FunctionElement method,
8539 5647 AssignmentOperator operator, Node rhs, A arg) {
8540 @override 5648 return handleStaticMethodCompound(node, method, operator, rhs, arg);
8541 R visitStaticMethodCompound(
8542 Send node,
8543 FunctionElement method,
8544 AssignmentOperator operator,
8545 Node rhs,
8546 A arg) {
8547 return handleStaticMethodCompound(
8548 node, method, operator, rhs, arg);
8549 } 5649 }
8550 5650
8551 @override 5651 @override
8552 R visitStaticMethodPostfix( 5652 R visitStaticMethodPostfix(
8553 Send node, 5653 Send node, FunctionElement method, IncDecOperator operator, A arg) {
8554 FunctionElement method, 5654 return handleStaticMethodPostfixPrefix(node, method, operator, arg,
8555 IncDecOperator operator, 5655 isPrefix: false);
8556 A arg) {
8557 return handleStaticMethodPostfixPrefix(
8558 node, method, operator, arg, isPrefix: false);
8559 } 5656 }
8560 5657
8561 @override 5658 @override
8562 R visitStaticMethodPrefix( 5659 R visitStaticMethodPrefix(
8563 Send node, 5660 Send node, FunctionElement method, IncDecOperator operator, A arg) {
8564 FunctionElement method, 5661 return handleStaticMethodPostfixPrefix(node, method, operator, arg,
8565 IncDecOperator operator, 5662 isPrefix: true);
8566 A arg) { 5663 }
8567 return handleStaticMethodPostfixPrefix( 5664
8568 node, method, operator, arg, isPrefix: true); 5665 @override
8569 } 5666 R visitUnresolvedStaticGetterCompound(Send node, Element element,
8570 5667 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
8571 @override
8572 R visitUnresolvedStaticGetterCompound(
8573 Send node,
8574 Element element,
8575 FunctionElement setter,
8576 AssignmentOperator operator,
8577 Node rhs,
8578 A arg) {
8579 return handleUnresolvedStaticGetterCompound( 5668 return handleUnresolvedStaticGetterCompound(
8580 node, element, setter, operator, rhs, arg); 5669 node, element, setter, operator, rhs, arg);
8581 } 5670 }
8582 5671
8583 @override 5672 @override
8584 R visitUnresolvedStaticGetterPostfix( 5673 R visitUnresolvedStaticGetterPostfix(Send node, Element element,
8585 Send node, 5674 FunctionElement setter, IncDecOperator operator, A arg) {
8586 Element element,
8587 FunctionElement setter,
8588 IncDecOperator operator,
8589 A arg) {
8590 return handleUnresolvedStaticGetterPostfixPrefix( 5675 return handleUnresolvedStaticGetterPostfixPrefix(
8591 node, element, setter, operator, arg, isPrefix: false); 5676 node, element, setter, operator, arg,
8592 } 5677 isPrefix: false);
8593 5678 }
8594 @override 5679
8595 R visitUnresolvedStaticGetterPrefix( 5680 @override
8596 Send node, 5681 R visitUnresolvedStaticGetterPrefix(Send node, Element element,
8597 Element element, 5682 FunctionElement setter, IncDecOperator operator, A arg) {
8598 FunctionElement setter,
8599 IncDecOperator operator,
8600 A arg) {
8601 return handleUnresolvedStaticGetterPostfixPrefix( 5683 return handleUnresolvedStaticGetterPostfixPrefix(
8602 node, element, setter, operator, arg, isPrefix: true); 5684 node, element, setter, operator, arg,
8603 } 5685 isPrefix: true);
8604 5686 }
8605 @override 5687
8606 R visitUnresolvedStaticSetterCompound( 5688 @override
8607 Send node, 5689 R visitUnresolvedStaticSetterCompound(Send node, FunctionElement getter,
8608 FunctionElement getter, 5690 Element element, AssignmentOperator operator, Node rhs, A arg) {
8609 Element element,
8610 AssignmentOperator operator,
8611 Node rhs,
8612 A arg) {
8613 return handleUnresolvedStaticSetterCompound( 5691 return handleUnresolvedStaticSetterCompound(
8614 node, getter, element, operator, rhs, arg); 5692 node, getter, element, operator, rhs, arg);
8615 } 5693 }
8616 5694
8617 @override 5695 @override
8618 R visitUnresolvedStaticSetterPostfix( 5696 R visitUnresolvedStaticSetterPostfix(Send node, FunctionElement getter,
8619 Send node, 5697 Element element, IncDecOperator operator, A arg) {
8620 FunctionElement getter,
8621 Element element,
8622 IncDecOperator operator,
8623 A arg) {
8624 return handleUnresolvedStaticSetterPostfixPrefix( 5698 return handleUnresolvedStaticSetterPostfixPrefix(
8625 node, getter, element, operator, arg, isPrefix: false); 5699 node, getter, element, operator, arg,
8626 } 5700 isPrefix: false);
8627 5701 }
8628 @override 5702
8629 R visitUnresolvedStaticSetterPrefix( 5703 @override
8630 Send node, 5704 R visitUnresolvedStaticSetterPrefix(Send node, FunctionElement getter,
8631 FunctionElement getter, 5705 Element element, IncDecOperator operator, A arg) {
8632 Element element,
8633 IncDecOperator operator,
8634 A arg) {
8635 return handleUnresolvedStaticSetterPostfixPrefix( 5706 return handleUnresolvedStaticSetterPostfixPrefix(
8636 node, getter, element, operator, arg, isPrefix: true); 5707 node, getter, element, operator, arg,
5708 isPrefix: true);
8637 } 5709 }
8638 } 5710 }
8639 5711
8640 /// Mixin that groups all non-compound `visitLocalX` and `visitParameterX` 5712 /// Mixin that groups all non-compound `visitLocalX` and `visitParameterX`
8641 /// methods by delegating calls to `handleLocalX` methods. 5713 /// methods by delegating calls to `handleLocalX` methods.
8642 /// 5714 ///
8643 /// This mixin is useful for the cases where both parameters, local variables, 5715 /// This mixin is useful for the cases where both parameters, local variables,
8644 /// and local functions, captured or not, are handled uniformly. 5716 /// and local functions, captured or not, are handled uniformly.
8645 abstract class BaseImplementationOfLocalsMixin<R, A> 5717 abstract class BaseImplementationOfLocalsMixin<R, A>
8646 implements SemanticSendVisitor<R, A> { 5718 implements SemanticSendVisitor<R, A> {
8647 R handleLocalGet( 5719 R handleLocalGet(Send node, LocalElement element, A arg);
8648 Send node,
8649 LocalElement element,
8650 A arg);
8651 5720
8652 R handleLocalInvoke( 5721 R handleLocalInvoke(Send node, LocalElement element, NodeList arguments,
8653 Send node, 5722 CallStructure callStructure, A arg);
8654 LocalElement element,
8655 NodeList arguments,
8656 CallStructure callStructure,
8657 A arg);
8658 5723
8659 R handleLocalSet( 5724 R handleLocalSet(SendSet node, LocalElement element, Node rhs, A arg);
8660 SendSet node,
8661 LocalElement element,
8662 Node rhs,
8663 A arg);
8664 5725
8665 R handleImmutableLocalSet( 5726 R handleImmutableLocalSet(
8666 SendSet node, 5727 SendSet node, LocalElement element, Node rhs, A arg);
8667 LocalElement element,
8668 Node rhs,
8669 A arg);
8670 5728
8671 @override 5729 @override
8672 R visitLocalFunctionGet( 5730 R visitLocalFunctionGet(Send node, LocalFunctionElement function, A arg) {
8673 Send node,
8674 LocalFunctionElement function,
8675 A arg) {
8676 return handleLocalGet(node, function, arg); 5731 return handleLocalGet(node, function, arg);
8677 } 5732 }
8678 5733
8679 @override 5734 @override
8680 R visitLocalFunctionInvoke( 5735 R visitLocalFunctionInvoke(Send node, LocalFunctionElement function,
8681 Send node, 5736 NodeList arguments, CallStructure callStructure, A arg) {
8682 LocalFunctionElement function,
8683 NodeList arguments,
8684 CallStructure callStructure,
8685 A arg) {
8686 return handleLocalInvoke(node, function, arguments, callStructure, arg); 5737 return handleLocalInvoke(node, function, arguments, callStructure, arg);
8687 } 5738 }
8688 5739
8689 @override 5740 @override
8690 R visitLocalFunctionIncompatibleInvoke( 5741 R visitLocalFunctionIncompatibleInvoke(
8691 Send node, 5742 Send node,
8692 LocalFunctionElement function, 5743 LocalFunctionElement function,
8693 NodeList arguments, 5744 NodeList arguments,
8694 CallStructure callStructure, 5745 CallStructure callStructure,
8695 A arg) { 5746 A arg) {
8696 return handleLocalInvoke(node, function, arguments, callStructure, arg); 5747 return handleLocalInvoke(node, function, arguments, callStructure, arg);
8697 } 5748 }
8698 5749
8699 @override 5750 @override
8700 R visitLocalVariableGet( 5751 R visitLocalVariableGet(Send node, LocalVariableElement variable, A arg) {
8701 Send node,
8702 LocalVariableElement variable,
8703 A arg) {
8704 return handleLocalGet(node, variable, arg); 5752 return handleLocalGet(node, variable, arg);
8705 } 5753 }
8706 5754
8707 @override 5755 @override
8708 R visitLocalVariableInvoke( 5756 R visitLocalVariableInvoke(Send node, LocalVariableElement variable,
8709 Send node, 5757 NodeList arguments, CallStructure callStructure, A arg) {
8710 LocalVariableElement variable,
8711 NodeList arguments,
8712 CallStructure callStructure,
8713 A arg) {
8714 return handleLocalInvoke(node, variable, arguments, callStructure, arg); 5758 return handleLocalInvoke(node, variable, arguments, callStructure, arg);
8715 } 5759 }
8716 5760
8717 @override 5761 @override
8718 R visitLocalVariableSet( 5762 R visitLocalVariableSet(
8719 SendSet node, 5763 SendSet node, LocalVariableElement variable, Node rhs, A arg) {
8720 LocalVariableElement variable,
8721 Node rhs,
8722 A arg) {
8723 return handleLocalSet(node, variable, rhs, arg); 5764 return handleLocalSet(node, variable, rhs, arg);
8724 } 5765 }
8725 5766
8726 @override 5767 @override
8727 R visitParameterGet( 5768 R visitParameterGet(Send node, ParameterElement parameter, A arg) {
8728 Send node,
8729 ParameterElement parameter,
8730 A arg) {
8731 return handleLocalGet(node, parameter, arg); 5769 return handleLocalGet(node, parameter, arg);
8732 } 5770 }
8733 5771
8734 @override 5772 @override
8735 R visitParameterInvoke( 5773 R visitParameterInvoke(Send node, ParameterElement parameter,
8736 Send node, 5774 NodeList arguments, CallStructure callStructure, A arg) {
8737 ParameterElement parameter,
8738 NodeList arguments,
8739 CallStructure callStructure,
8740 A arg) {
8741 return handleLocalInvoke(node, parameter, arguments, callStructure, arg); 5775 return handleLocalInvoke(node, parameter, arguments, callStructure, arg);
8742 } 5776 }
8743 5777
8744 @override 5778 @override
8745 R visitParameterSet( 5779 R visitParameterSet(
8746 SendSet node, 5780 SendSet node, ParameterElement parameter, Node rhs, A arg) {
8747 ParameterElement parameter,
8748 Node rhs,
8749 A arg) {
8750 return handleLocalSet(node, parameter, rhs, arg); 5781 return handleLocalSet(node, parameter, rhs, arg);
8751 } 5782 }
8752 5783
8753 @override 5784 @override
8754 R visitFinalLocalVariableSet( 5785 R visitFinalLocalVariableSet(
8755 SendSet node, 5786 SendSet node, LocalVariableElement variable, Node rhs, A arg) {
8756 LocalVariableElement variable,
8757 Node rhs,
8758 A arg) {
8759 return handleImmutableLocalSet(node, variable, rhs, arg); 5787 return handleImmutableLocalSet(node, variable, rhs, arg);
8760 } 5788 }
8761 5789
8762 @override 5790 @override
8763 R visitFinalParameterSet( 5791 R visitFinalParameterSet(
8764 SendSet node, 5792 SendSet node, ParameterElement parameter, Node rhs, A arg) {
8765 ParameterElement parameter,
8766 Node rhs,
8767 A arg) {
8768 return handleImmutableLocalSet(node, parameter, rhs, arg); 5793 return handleImmutableLocalSet(node, parameter, rhs, arg);
8769 } 5794 }
8770 5795
8771 @override 5796 @override
8772 R visitLocalFunctionSet( 5797 R visitLocalFunctionSet(
8773 SendSet node, 5798 SendSet node, LocalFunctionElement function, Node rhs, A arg) {
8774 LocalFunctionElement function,
8775 Node rhs,
8776 A arg) {
8777 return handleImmutableLocalSet(node, function, rhs, arg); 5799 return handleImmutableLocalSet(node, function, rhs, arg);
8778 } 5800 }
8779 } 5801 }
8780 5802
8781 /// Mixin that groups all compound `visitLocalX` and `visitParameterX` methods 5803 /// Mixin that groups all compound `visitLocalX` and `visitParameterX` methods
8782 /// by delegating calls to `handleLocalX` methods. 5804 /// by delegating calls to `handleLocalX` methods.
8783 /// 5805 ///
8784 /// This mixin is useful for the cases where both parameters, local variables, 5806 /// This mixin is useful for the cases where both parameters, local variables,
8785 /// and local functions, captured or not, are handled uniformly. 5807 /// and local functions, captured or not, are handled uniformly.
8786 abstract class BaseImplementationOfLocalCompoundsMixin<R, A> 5808 abstract class BaseImplementationOfLocalCompoundsMixin<R, A>
8787 implements SemanticSendVisitor<R, A> { 5809 implements SemanticSendVisitor<R, A> {
8788 R handleLocalCompound( 5810 R handleLocalCompound(Send node, LocalElement element,
8789 Send node, 5811 AssignmentOperator operator, Node rhs, A arg);
8790 LocalElement element,
8791 AssignmentOperator operator,
8792 Node rhs,
8793 A arg);
8794 5812
8795 R handleLocalPostfixPrefix( 5813 R handleLocalPostfixPrefix(
8796 Send node, 5814 Send node, LocalElement element, IncDecOperator operator, A arg,
8797 LocalElement element,
8798 IncDecOperator operator,
8799 A arg,
8800 {bool isPrefix}); 5815 {bool isPrefix});
8801 5816
8802 @override 5817 @override
8803 R visitLocalVariableCompound( 5818 R visitLocalVariableCompound(Send node, LocalVariableElement variable,
8804 Send node, 5819 AssignmentOperator operator, Node rhs, A arg) {
8805 LocalVariableElement variable,
8806 AssignmentOperator operator,
8807 Node rhs,
8808 A arg) {
8809 return handleLocalCompound(node, variable, operator, rhs, arg); 5820 return handleLocalCompound(node, variable, operator, rhs, arg);
8810 } 5821 }
8811 5822
8812 @override 5823 @override
8813 R visitLocalVariablePostfix( 5824 R visitLocalVariablePostfix(Send node, LocalVariableElement variable,
8814 Send node, 5825 IncDecOperator operator, A arg) {
8815 LocalVariableElement variable, 5826 return handleLocalPostfixPrefix(node, variable, operator, arg,
8816 IncDecOperator operator, 5827 isPrefix: false);
8817 A arg) {
8818 return handleLocalPostfixPrefix(
8819 node, variable, operator, arg, isPrefix: false);
8820 } 5828 }
8821 5829
8822 @override 5830 @override
8823 R visitLocalVariablePrefix( 5831 R visitLocalVariablePrefix(Send node, LocalVariableElement variable,
8824 Send node, 5832 IncDecOperator operator, A arg) {
8825 LocalVariableElement variable, 5833 return handleLocalPostfixPrefix(node, variable, operator, arg,
8826 IncDecOperator operator, 5834 isPrefix: true);
8827 A arg) {
8828 return handleLocalPostfixPrefix(
8829 node, variable, operator, arg, isPrefix: true);
8830 } 5835 }
8831 5836
8832 @override 5837 @override
8833 R visitParameterCompound( 5838 R visitParameterCompound(Send node, ParameterElement parameter,
8834 Send node, 5839 AssignmentOperator operator, Node rhs, A arg) {
8835 ParameterElement parameter,
8836 AssignmentOperator operator,
8837 Node rhs,
8838 A arg) {
8839 return handleLocalCompound(node, parameter, operator, rhs, arg); 5840 return handleLocalCompound(node, parameter, operator, rhs, arg);
8840 } 5841 }
8841 5842
8842 @override 5843 @override
8843 R visitParameterPostfix( 5844 R visitParameterPostfix(
8844 Send node, 5845 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
8845 ParameterElement parameter, 5846 return handleLocalPostfixPrefix(node, parameter, operator, arg,
8846 IncDecOperator operator, 5847 isPrefix: false);
8847 A arg) {
8848 return handleLocalPostfixPrefix(
8849 node, parameter, operator, arg, isPrefix: false);
8850 } 5848 }
8851 5849
8852 @override 5850 @override
8853 R visitParameterPrefix( 5851 R visitParameterPrefix(
8854 Send node, 5852 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
8855 ParameterElement parameter, 5853 return handleLocalPostfixPrefix(node, parameter, operator, arg,
8856 IncDecOperator operator, 5854 isPrefix: true);
8857 A arg) {
8858 return handleLocalPostfixPrefix(
8859 node, parameter, operator, arg, isPrefix: true);
8860 } 5855 }
8861 } 5856 }
8862 5857
8863 /// Mixin that groups all `visitConstantX` and `visitXTypeLiteralY` methods for 5858 /// Mixin that groups all `visitConstantX` and `visitXTypeLiteralY` methods for
8864 /// constant type literals by delegating calls to `handleConstantX` methods. 5859 /// constant type literals by delegating calls to `handleConstantX` methods.
8865 /// 5860 ///
8866 /// This mixin is useful for the cases where expressions on constants are 5861 /// This mixin is useful for the cases where expressions on constants are
8867 /// handled uniformly. 5862 /// handled uniformly.
8868 abstract class BaseImplementationOfConstantsMixin<R, A> 5863 abstract class BaseImplementationOfConstantsMixin<R, A>
8869 implements SemanticSendVisitor<R, A> { 5864 implements SemanticSendVisitor<R, A> {
8870 R handleConstantGet( 5865 R handleConstantGet(Node node, ConstantExpression constant, A arg);
8871 Node node,
8872 ConstantExpression constant,
8873 A arg);
8874 5866
8875 R handleConstantInvoke( 5867 R handleConstantInvoke(Send node, ConstantExpression constant,
8876 Send node, 5868 NodeList arguments, CallStructure callStructure, A arg);
8877 ConstantExpression constant,
8878 NodeList arguments,
8879 CallStructure callStructure,
8880 A arg);
8881 5869
8882 @override 5870 @override
8883 R visitClassTypeLiteralGet( 5871 R visitClassTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
8884 Send node,
8885 ConstantExpression constant,
8886 A arg) {
8887 return handleConstantGet(node, constant, arg); 5872 return handleConstantGet(node, constant, arg);
8888 } 5873 }
8889 5874
8890 @override 5875 @override
8891 R visitClassTypeLiteralInvoke( 5876 R visitClassTypeLiteralInvoke(Send node, ConstantExpression constant,
8892 Send node, 5877 NodeList arguments, CallStructure callStructure, A arg) {
8893 ConstantExpression constant,
8894 NodeList arguments,
8895 CallStructure callStructure,
8896 A arg) {
8897 return handleConstantInvoke(node, constant, arguments, callStructure, arg); 5878 return handleConstantInvoke(node, constant, arguments, callStructure, arg);
8898 } 5879 }
8899 5880
8900 @override 5881 @override
8901 R visitConstConstructorInvoke( 5882 R visitConstConstructorInvoke(
8902 NewExpression node, 5883 NewExpression node, ConstructedConstantExpression constant, A arg) {
8903 ConstructedConstantExpression constant,
8904 A arg) {
8905 return handleConstantGet(node, constant, arg); 5884 return handleConstantGet(node, constant, arg);
8906 } 5885 }
8907 5886
8908 @override 5887 @override
8909 R visitBoolFromEnvironmentConstructorInvoke( 5888 R visitBoolFromEnvironmentConstructorInvoke(NewExpression node,
8910 NewExpression node, 5889 BoolFromEnvironmentConstantExpression constant, A arg) {
8911 BoolFromEnvironmentConstantExpression constant,
8912 A arg) {
8913 return handleConstantGet(node, constant, arg); 5890 return handleConstantGet(node, constant, arg);
8914 } 5891 }
8915 5892
8916 @override 5893 @override
8917 R visitIntFromEnvironmentConstructorInvoke( 5894 R visitIntFromEnvironmentConstructorInvoke(NewExpression node,
8918 NewExpression node, 5895 IntFromEnvironmentConstantExpression constant, A arg) {
8919 IntFromEnvironmentConstantExpression constant,
8920 A arg) {
8921 return handleConstantGet(node, constant, arg); 5896 return handleConstantGet(node, constant, arg);
8922 } 5897 }
8923 5898
8924 @override 5899 @override
8925 R visitStringFromEnvironmentConstructorInvoke( 5900 R visitStringFromEnvironmentConstructorInvoke(NewExpression node,
8926 NewExpression node, 5901 StringFromEnvironmentConstantExpression constant, A arg) {
8927 StringFromEnvironmentConstantExpression constant,
8928 A arg) {
8929 return handleConstantGet(node, constant, arg); 5902 return handleConstantGet(node, constant, arg);
8930 } 5903 }
8931 5904
8932 @override 5905 @override
8933 R visitConstantGet( 5906 R visitConstantGet(Send node, ConstantExpression constant, A arg) {
8934 Send node,
8935 ConstantExpression constant,
8936 A arg) {
8937 return handleConstantGet(node, constant, arg); 5907 return handleConstantGet(node, constant, arg);
8938 } 5908 }
8939 5909
8940 @override 5910 @override
8941 R visitConstantInvoke( 5911 R visitConstantInvoke(Send node, ConstantExpression constant,
8942 Send node, 5912 NodeList arguments, CallStructure callStructure, A arg) {
8943 ConstantExpression constant,
8944 NodeList arguments,
8945 CallStructure callStructure,
8946 A arg) {
8947 return handleConstantInvoke(node, constant, arguments, callStructure, arg); 5913 return handleConstantInvoke(node, constant, arguments, callStructure, arg);
8948 } 5914 }
8949 5915
8950 @override 5916 @override
8951 R visitDynamicTypeLiteralGet( 5917 R visitDynamicTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
8952 Send node,
8953 ConstantExpression constant,
8954 A arg) {
8955 return handleConstantGet(node, constant, arg); 5918 return handleConstantGet(node, constant, arg);
8956 } 5919 }
8957 5920
8958 @override 5921 @override
8959 R visitDynamicTypeLiteralInvoke( 5922 R visitDynamicTypeLiteralInvoke(Send node, ConstantExpression constant,
8960 Send node, 5923 NodeList arguments, CallStructure callStructure, A arg) {
8961 ConstantExpression constant,
8962 NodeList arguments,
8963 CallStructure callStructure,
8964 A arg) {
8965 return handleConstantInvoke(node, constant, arguments, callStructure, arg); 5924 return handleConstantInvoke(node, constant, arguments, callStructure, arg);
8966 } 5925 }
8967 5926
8968 @override 5927 @override
8969 R visitTypedefTypeLiteralGet( 5928 R visitTypedefTypeLiteralGet(Send node, ConstantExpression constant, A arg) {
8970 Send node,
8971 ConstantExpression constant,
8972 A arg) {
8973 return handleConstantGet(node, constant, arg); 5929 return handleConstantGet(node, constant, arg);
8974 } 5930 }
8975 5931
8976 @override 5932 @override
8977 R visitTypedefTypeLiteralInvoke( 5933 R visitTypedefTypeLiteralInvoke(Send node, ConstantExpression constant,
8978 Send node, 5934 NodeList arguments, CallStructure callStructure, A arg) {
8979 ConstantExpression constant,
8980 NodeList arguments,
8981 CallStructure callStructure,
8982 A arg) {
8983 return handleConstantInvoke(node, constant, arguments, callStructure, arg); 5935 return handleConstantInvoke(node, constant, arguments, callStructure, arg);
8984 } 5936 }
8985 } 5937 }
8986 5938
8987 /// Mixin that groups all non-compound `visitDynamicPropertyX` and 5939 /// Mixin that groups all non-compound `visitDynamicPropertyX` and
8988 /// `visitThisPropertyY` methods for by delegating calls to `handleDynamicX` 5940 /// `visitThisPropertyY` methods for by delegating calls to `handleDynamicX`
8989 /// methods, providing `null` as the receiver for the this properties. 5941 /// methods, providing `null` as the receiver for the this properties.
8990 /// 5942 ///
8991 /// This mixin is useful for the cases where dynamic and this properties are 5943 /// This mixin is useful for the cases where dynamic and this properties are
8992 /// handled uniformly. 5944 /// handled uniformly.
8993 abstract class BaseImplementationOfDynamicsMixin<R, A> 5945 abstract class BaseImplementationOfDynamicsMixin<R, A>
8994 implements SemanticSendVisitor<R, A> { 5946 implements SemanticSendVisitor<R, A> {
8995 R handleDynamicGet( 5947 R handleDynamicGet(Send node, Node receiver, Name name, A arg);
8996 Send node,
8997 Node receiver,
8998 Name name,
8999 A arg);
9000 5948
9001 R handleDynamicInvoke( 5949 R handleDynamicInvoke(
9002 Send node, 5950 Send node, Node receiver, NodeList arguments, Selector selector, A arg);
9003 Node receiver,
9004 NodeList arguments,
9005 Selector selector,
9006 A arg);
9007 5951
9008 R handleDynamicSet( 5952 R handleDynamicSet(SendSet node, Node receiver, Name name, Node rhs, A arg);
9009 SendSet node,
9010 Node receiver,
9011 Name name,
9012 Node rhs,
9013 A arg);
9014 5953
9015 @override 5954 @override
9016 R visitDynamicPropertyGet( 5955 R visitDynamicPropertyGet(Send node, Node receiver, Name name, A arg) {
9017 Send node,
9018 Node receiver,
9019 Name name,
9020 A arg) {
9021 return handleDynamicGet(node, receiver, name, arg); 5956 return handleDynamicGet(node, receiver, name, arg);
9022 } 5957 }
9023 5958
9024 @override 5959 @override
9025 R visitIfNotNullDynamicPropertyGet( 5960 R visitIfNotNullDynamicPropertyGet(
9026 Send node, 5961 Send node, Node receiver, Name name, A arg) {
9027 Node receiver,
9028 Name name,
9029 A arg) {
9030 // TODO(johnniwinther): should these redirect to handleDynamicX? 5962 // TODO(johnniwinther): should these redirect to handleDynamicX?
9031 return handleDynamicGet(node, receiver, name, arg); 5963 return handleDynamicGet(node, receiver, name, arg);
9032 } 5964 }
9033 5965
9034 @override 5966 @override
9035 R visitDynamicPropertyInvoke( 5967 R visitDynamicPropertyInvoke(
9036 Send node, 5968 Send node, Node receiver, NodeList arguments, Selector selector, A arg) {
9037 Node receiver,
9038 NodeList arguments,
9039 Selector selector,
9040 A arg) {
9041 return handleDynamicInvoke(node, receiver, arguments, selector, arg); 5969 return handleDynamicInvoke(node, receiver, arguments, selector, arg);
9042 } 5970 }
9043 5971
9044 @override 5972 @override
9045 R visitIfNotNullDynamicPropertyInvoke( 5973 R visitIfNotNullDynamicPropertyInvoke(
9046 Send node, 5974 Send node, Node receiver, NodeList arguments, Selector selector, A arg) {
9047 Node receiver,
9048 NodeList arguments,
9049 Selector selector,
9050 A arg) {
9051 return handleDynamicInvoke(node, receiver, arguments, selector, arg); 5975 return handleDynamicInvoke(node, receiver, arguments, selector, arg);
9052 } 5976 }
9053 5977
9054 @override 5978 @override
9055 R visitDynamicPropertySet( 5979 R visitDynamicPropertySet(
9056 SendSet node, 5980 SendSet node, Node receiver, Name name, Node rhs, A arg) {
9057 Node receiver,
9058 Name name,
9059 Node rhs,
9060 A arg) {
9061 return handleDynamicSet(node, receiver, name, rhs, arg); 5981 return handleDynamicSet(node, receiver, name, rhs, arg);
9062 } 5982 }
9063 5983
9064 @override 5984 @override
9065 R visitIfNotNullDynamicPropertySet( 5985 R visitIfNotNullDynamicPropertySet(
9066 SendSet node, 5986 SendSet node, Node receiver, Name name, Node rhs, A arg) {
9067 Node receiver,
9068 Name name,
9069 Node rhs,
9070 A arg) {
9071 return handleDynamicSet(node, receiver, name, rhs, arg); 5987 return handleDynamicSet(node, receiver, name, rhs, arg);
9072 } 5988 }
9073 5989
9074 @override 5990 @override
9075 R visitThisPropertyGet( 5991 R visitThisPropertyGet(Send node, Name name, A arg) {
9076 Send node,
9077 Name name,
9078 A arg) {
9079 return handleDynamicGet(node, null, name, arg); 5992 return handleDynamicGet(node, null, name, arg);
9080 } 5993 }
9081 5994
9082 @override 5995 @override
9083 R visitThisPropertyInvoke( 5996 R visitThisPropertyInvoke(
9084 Send node, 5997 Send node, NodeList arguments, Selector selector, A arg) {
9085 NodeList arguments,
9086 Selector selector,
9087 A arg) {
9088 return handleDynamicInvoke(node, null, arguments, selector, arg); 5998 return handleDynamicInvoke(node, null, arguments, selector, arg);
9089 } 5999 }
9090 6000
9091 @override 6001 @override
9092 R visitThisPropertySet( 6002 R visitThisPropertySet(SendSet node, Name name, Node rhs, A arg) {
9093 SendSet node,
9094 Name name,
9095 Node rhs,
9096 A arg) {
9097 return handleDynamicSet(node, null, name, rhs, arg); 6003 return handleDynamicSet(node, null, name, rhs, arg);
9098 } 6004 }
9099 } 6005 }
9100 6006
9101 /// Mixin that groups all compounds of `visitDynamicPropertyX` and 6007 /// Mixin that groups all compounds of `visitDynamicPropertyX` and
9102 /// `visitThisPropertyY` methods for by delegating calls to `handleDynamicX` 6008 /// `visitThisPropertyY` methods for by delegating calls to `handleDynamicX`
9103 /// methods, providing `null` as the receiver for the this properties. 6009 /// methods, providing `null` as the receiver for the this properties.
9104 /// 6010 ///
9105 /// This mixin is useful for the cases where dynamic and this properties are 6011 /// This mixin is useful for the cases where dynamic and this properties are
9106 /// handled uniformly. 6012 /// handled uniformly.
9107 abstract class BaseImplementationOfDynamicCompoundsMixin<R, A> 6013 abstract class BaseImplementationOfDynamicCompoundsMixin<R, A>
9108 implements SemanticSendVisitor<R, A> { 6014 implements SemanticSendVisitor<R, A> {
9109 R handleDynamicCompound( 6015 R handleDynamicCompound(Send node, Node receiver, Name name,
9110 Send node, 6016 AssignmentOperator operator, Node rhs, A arg);
9111 Node receiver,
9112 Name name,
9113 AssignmentOperator operator,
9114 Node rhs,
9115 A arg);
9116 6017
9117 R handleDynamicPostfixPrefix( 6018 R handleDynamicPostfixPrefix(
9118 Send node, 6019 Send node, Node receiver, Name name, IncDecOperator operator, A arg,
9119 Node receiver,
9120 Name name,
9121 IncDecOperator operator,
9122 A arg,
9123 {bool isPrefix}); 6020 {bool isPrefix});
9124 6021
9125 R handleDynamicIndexPostfixPrefix( 6022 R handleDynamicIndexPostfixPrefix(
9126 Send node, 6023 Send node, Node receiver, Node index, IncDecOperator operator, A arg,
9127 Node receiver,
9128 Node index,
9129 IncDecOperator operator,
9130 A arg,
9131 {bool isPrefix}); 6024 {bool isPrefix});
9132 6025
9133 @override 6026 @override
9134 R visitDynamicPropertyCompound( 6027 R visitDynamicPropertyCompound(Send node, Node receiver, Name name,
9135 Send node, 6028 AssignmentOperator operator, Node rhs, A arg) {
9136 Node receiver, 6029 return handleDynamicCompound(node, receiver, name, operator, rhs, arg);
9137 Name name,
9138 AssignmentOperator operator,
9139 Node rhs,
9140 A arg) {
9141 return handleDynamicCompound(
9142 node, receiver, name, operator, rhs, arg);
9143 } 6030 }
9144 6031
9145 @override 6032 @override
9146 R visitIfNotNullDynamicPropertyCompound( 6033 R visitIfNotNullDynamicPropertyCompound(Send node, Node receiver, Name name,
9147 Send node, 6034 AssignmentOperator operator, Node rhs, A arg) {
9148 Node receiver, 6035 return handleDynamicCompound(node, receiver, name, operator, rhs, arg);
9149 Name name,
9150 AssignmentOperator operator,
9151 Node rhs,
9152 A arg) {
9153 return handleDynamicCompound(
9154 node, receiver, name, operator, rhs, arg);
9155 } 6036 }
9156 6037
9157 @override 6038 @override
9158 R visitDynamicPropertyPostfix( 6039 R visitDynamicPropertyPostfix(
9159 Send node, 6040 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
9160 Node receiver, 6041 return handleDynamicPostfixPrefix(node, receiver, name, operator, arg,
9161 Name name, 6042 isPrefix: false);
9162 IncDecOperator operator,
9163 A arg) {
9164 return handleDynamicPostfixPrefix(
9165 node, receiver, name, operator, arg, isPrefix: false);
9166 } 6043 }
9167 6044
9168 @override 6045 @override
9169 R visitIfNotNullDynamicPropertyPostfix( 6046 R visitIfNotNullDynamicPropertyPostfix(
9170 Send node, 6047 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
9171 Node receiver, 6048 return handleDynamicPostfixPrefix(node, receiver, name, operator, arg,
9172 Name name, 6049 isPrefix: false);
9173 IncDecOperator operator,
9174 A arg) {
9175 return handleDynamicPostfixPrefix(
9176 node, receiver, name, operator, arg, isPrefix: false);
9177 } 6050 }
9178 6051
9179 @override 6052 @override
9180 R visitDynamicPropertyPrefix( 6053 R visitDynamicPropertyPrefix(
9181 Send node, 6054 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
9182 Node receiver, 6055 return handleDynamicPostfixPrefix(node, receiver, name, operator, arg,
9183 Name name, 6056 isPrefix: true);
9184 IncDecOperator operator,
9185 A arg) {
9186 return handleDynamicPostfixPrefix(
9187 node, receiver, name, operator, arg, isPrefix: true);
9188 } 6057 }
9189 6058
9190 @override 6059 @override
9191 R visitIfNotNullDynamicPropertyPrefix( 6060 R visitIfNotNullDynamicPropertyPrefix(
9192 Send node, 6061 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
9193 Node receiver, 6062 return handleDynamicPostfixPrefix(node, receiver, name, operator, arg,
9194 Name name, 6063 isPrefix: true);
9195 IncDecOperator operator,
9196 A arg) {
9197 return handleDynamicPostfixPrefix(
9198 node, receiver, name, operator, arg, isPrefix: true);
9199 } 6064 }
9200 6065
9201 @override 6066 @override
9202 R visitThisPropertyCompound( 6067 R visitThisPropertyCompound(
9203 Send node, 6068 Send node, Name name, AssignmentOperator operator, Node rhs, A arg) {
9204 Name name,
9205 AssignmentOperator operator,
9206 Node rhs,
9207 A arg) {
9208 return handleDynamicCompound(node, null, name, operator, rhs, arg); 6069 return handleDynamicCompound(node, null, name, operator, rhs, arg);
9209 } 6070 }
9210 6071
9211 @override 6072 @override
9212 R visitThisPropertyPostfix( 6073 R visitThisPropertyPostfix(
9213 Send node, 6074 Send node, Name name, IncDecOperator operator, A arg) {
9214 Name name, 6075 return handleDynamicPostfixPrefix(node, null, name, operator, arg,
9215 IncDecOperator operator, 6076 isPrefix: false);
9216 A arg) {
9217 return handleDynamicPostfixPrefix(
9218 node, null, name, operator, arg, isPrefix: false);
9219 } 6077 }
9220 6078
9221 @override 6079 @override
9222 R visitThisPropertyPrefix( 6080 R visitThisPropertyPrefix(
9223 Send node, 6081 Send node, Name name, IncDecOperator operator, A arg) {
9224 Name name, 6082 return handleDynamicPostfixPrefix(node, null, name, operator, arg,
9225 IncDecOperator operator, 6083 isPrefix: true);
9226 A arg) {
9227 return handleDynamicPostfixPrefix(
9228 node, null, name, operator, arg, isPrefix: true);
9229 } 6084 }
9230 6085
9231 @override 6086 @override
9232 R visitIndexPostfix( 6087 R visitIndexPostfix(
9233 Send node, 6088 Send node, Node receiver, Node index, IncDecOperator operator, A arg) {
9234 Node receiver, 6089 return handleDynamicIndexPostfixPrefix(node, receiver, index, operator, arg,
9235 Node index, 6090 isPrefix: false);
9236 IncDecOperator operator,
9237 A arg) {
9238 return handleDynamicIndexPostfixPrefix(
9239 node, receiver, index, operator, arg, isPrefix: false);
9240 } 6091 }
9241 6092
9242 @override 6093 @override
9243 R visitIndexPrefix( 6094 R visitIndexPrefix(
9244 Send node, 6095 Send node, Node receiver, Node index, IncDecOperator operator, A arg) {
9245 Node receiver, 6096 return handleDynamicIndexPostfixPrefix(node, receiver, index, operator, arg,
9246 Node index, 6097 isPrefix: true);
9247 IncDecOperator operator,
9248 A arg) {
9249 return handleDynamicIndexPostfixPrefix(
9250 node, receiver, index, operator, arg, isPrefix: true);
9251 } 6098 }
9252 } 6099 }
9253 6100
9254 /// The getter kind for statically resolved compound expressions. 6101 /// The getter kind for statically resolved compound expressions.
9255 enum CompoundGetter { 6102 enum CompoundGetter {
9256 /// The compound reads from a field. 6103 /// The compound reads from a field.
9257 FIELD, 6104 FIELD,
9258 6105
9259 /// The compound reads from a getter. 6106 /// The compound reads from a getter.
9260 GETTER, 6107 GETTER,
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
9324 AssignmentCompound(this.assignmentOperator, this.rhs); 6171 AssignmentCompound(this.assignmentOperator, this.rhs);
9325 6172
9326 CompoundKind get kind => CompoundKind.ASSIGNMENT; 6173 CompoundKind get kind => CompoundKind.ASSIGNMENT;
9327 6174
9328 BinaryOperator get operator => assignmentOperator.binaryOperator; 6175 BinaryOperator get operator => assignmentOperator.binaryOperator;
9329 } 6176 }
9330 6177
9331 /// Simplified handling of compound assignments and prefix/postfix expressions. 6178 /// Simplified handling of compound assignments and prefix/postfix expressions.
9332 abstract class BaseImplementationOfCompoundsMixin<R, A> 6179 abstract class BaseImplementationOfCompoundsMixin<R, A>
9333 implements SemanticSendVisitor<R, A> { 6180 implements SemanticSendVisitor<R, A> {
9334
9335 /// Handle a super compounds, like `super.foo += 42` or `--super.bar`. 6181 /// Handle a super compounds, like `super.foo += 42` or `--super.bar`.
9336 R handleSuperCompounds( 6182 R handleSuperCompounds(
9337 SendSet node, 6183 SendSet node,
9338 Element getter, 6184 Element getter,
9339 CompoundGetter getterKind, 6185 CompoundGetter getterKind,
9340 Element setter, 6186 Element setter,
9341 CompoundSetter setterKind, 6187 CompoundSetter setterKind,
9342 CompoundRhs rhs, 6188 CompoundRhs rhs,
9343 A arg); 6189 A arg);
9344 6190
9345 /// Handle a static or top level compounds, like `foo += 42` or `--bar`. 6191 /// Handle a static or top level compounds, like `foo += 42` or `--bar`.
9346 R handleStaticCompounds( 6192 R handleStaticCompounds(
9347 SendSet node, 6193 SendSet node,
9348 Element getter, 6194 Element getter,
9349 CompoundGetter getterKind, 6195 CompoundGetter getterKind,
9350 Element setter, 6196 Element setter,
9351 CompoundSetter setterKind, 6197 CompoundSetter setterKind,
9352 CompoundRhs rhs, 6198 CompoundRhs rhs,
9353 A arg); 6199 A arg);
9354 6200
9355 /// Handle a local compounds, like `foo += 42` or `--bar`. If [isSetterValid] 6201 /// Handle a local compounds, like `foo += 42` or `--bar`. If [isSetterValid]
9356 /// is false [local] is unassignable. 6202 /// is false [local] is unassignable.
9357 R handleLocalCompounds( 6203 R handleLocalCompounds(
9358 SendSet node, 6204 SendSet node, LocalElement local, CompoundRhs rhs, A arg,
9359 LocalElement local,
9360 CompoundRhs rhs,
9361 A arg,
9362 {bool isSetterValid}); 6205 {bool isSetterValid});
9363 6206
9364 /// Handle a compounds on a type literal constant, like `Object += 42` or 6207 /// Handle a compounds on a type literal constant, like `Object += 42` or
9365 /// `--Object`. 6208 /// `--Object`.
9366 R handleTypeLiteralConstantCompounds( 6209 R handleTypeLiteralConstantCompounds(
9367 SendSet node, 6210 SendSet node, ConstantExpression constant, CompoundRhs rhs, A arg);
9368 ConstantExpression constant,
9369 CompoundRhs rhs,
9370 A arg);
9371 6211
9372 /// Handle a compounds on a type variable type literal, like `T += 42` or 6212 /// Handle a compounds on a type variable type literal, like `T += 42` or
9373 /// `--T`. 6213 /// `--T`.
9374 R handleTypeVariableTypeLiteralCompounds( 6214 R handleTypeVariableTypeLiteralCompounds(
9375 SendSet node, 6215 SendSet node, TypeVariableElement typeVariable, CompoundRhs rhs, A arg);
9376 TypeVariableElement typeVariable,
9377 CompoundRhs rhs,
9378 A arg);
9379 6216
9380 /// Handle a dynamic compounds, like `o.foo += 42` or `--o.foo`. [receiver] is 6217 /// Handle a dynamic compounds, like `o.foo += 42` or `--o.foo`. [receiver] is
9381 /// `null` for properties on `this`, like `--this.foo` or `--foo`. 6218 /// `null` for properties on `this`, like `--this.foo` or `--foo`.
9382 R handleDynamicCompounds( 6219 R handleDynamicCompounds(
9383 Send node, 6220 Send node, Node receiver, Name name, CompoundRhs rhs, A arg);
9384 Node receiver, 6221
9385 Name name, 6222 R visitDynamicPropertyCompound(Send node, Node receiver, Name name,
9386 CompoundRhs rhs, 6223 AssignmentOperator operator, Node rhs, A arg) {
9387 A arg);
9388
9389 R visitDynamicPropertyCompound(
9390 Send node,
9391 Node receiver,
9392 Name name,
9393 AssignmentOperator operator,
9394 Node rhs,
9395 A arg) {
9396 return handleDynamicCompounds( 6224 return handleDynamicCompounds(
9397 node, 6225 node, receiver, name, new AssignmentCompound(operator, rhs), arg);
9398 receiver, 6226 }
9399 name, 6227
9400 new AssignmentCompound(operator, rhs), 6228 R visitIfNotNullDynamicPropertyCompound(Send node, Node receiver, Name name,
9401 arg); 6229 AssignmentOperator operator, Node rhs, A arg) {
9402 }
9403
9404 R visitIfNotNullDynamicPropertyCompound(
9405 Send node,
9406 Node receiver,
9407 Name name,
9408 AssignmentOperator operator,
9409 Node rhs,
9410 A arg) {
9411 return handleDynamicCompounds( 6230 return handleDynamicCompounds(
9412 node, 6231 node, receiver, name, new AssignmentCompound(operator, rhs), arg);
9413 receiver,
9414 name,
9415 new AssignmentCompound(operator, rhs),
9416 arg);
9417 } 6232 }
9418 6233
9419 @override 6234 @override
9420 R visitThisPropertyCompound( 6235 R visitThisPropertyCompound(
9421 Send node, 6236 Send node, Name name, AssignmentOperator operator, Node rhs, A arg) {
9422 Name name,
9423 AssignmentOperator operator,
9424 Node rhs,
9425 A arg) {
9426 return handleDynamicCompounds( 6237 return handleDynamicCompounds(
9427 node, 6238 node, null, name, new AssignmentCompound(operator, rhs), arg);
9428 null, 6239 }
9429 name, 6240
9430 new AssignmentCompound(operator, rhs), 6241 @override
9431 arg); 6242 R visitParameterCompound(Send node, ParameterElement parameter,
9432 } 6243 AssignmentOperator operator, Node rhs, A arg) {
9433 6244 return handleLocalCompounds(
9434 @override 6245 node, parameter, new AssignmentCompound(operator, rhs), arg,
9435 R visitParameterCompound(
9436 Send node,
9437 ParameterElement parameter,
9438 AssignmentOperator operator,
9439 Node rhs,
9440 A arg) {
9441 return handleLocalCompounds(
9442 node,
9443 parameter,
9444 new AssignmentCompound(operator, rhs),
9445 arg,
9446 isSetterValid: true); 6246 isSetterValid: true);
9447 } 6247 }
9448 6248
9449 @override 6249 @override
9450 R visitFinalParameterCompound( 6250 R visitFinalParameterCompound(Send node, ParameterElement parameter,
9451 Send node, 6251 AssignmentOperator operator, Node rhs, A arg) {
9452 ParameterElement parameter, 6252 return handleLocalCompounds(
9453 AssignmentOperator operator, 6253 node, parameter, new AssignmentCompound(operator, rhs), arg,
9454 Node rhs,
9455 A arg) {
9456 return handleLocalCompounds(
9457 node,
9458 parameter,
9459 new AssignmentCompound(operator, rhs),
9460 arg,
9461 isSetterValid: false); 6254 isSetterValid: false);
9462 } 6255 }
9463 6256
9464 @override 6257 @override
9465 R visitLocalVariableCompound( 6258 R visitLocalVariableCompound(Send node, LocalVariableElement variable,
9466 Send node, 6259 AssignmentOperator operator, Node rhs, A arg) {
9467 LocalVariableElement variable, 6260 return handleLocalCompounds(
9468 AssignmentOperator operator, 6261 node, variable, new AssignmentCompound(operator, rhs), arg,
9469 Node rhs,
9470 A arg) {
9471 return handleLocalCompounds(
9472 node,
9473 variable,
9474 new AssignmentCompound(operator, rhs),
9475 arg,
9476 isSetterValid: true); 6262 isSetterValid: true);
9477 } 6263 }
9478 6264
9479 @override 6265 @override
9480 R visitFinalLocalVariableCompound( 6266 R visitFinalLocalVariableCompound(Send node, LocalVariableElement variable,
9481 Send node, 6267 AssignmentOperator operator, Node rhs, A arg) {
9482 LocalVariableElement variable, 6268 return handleLocalCompounds(
9483 AssignmentOperator operator, 6269 node, variable, new AssignmentCompound(operator, rhs), arg,
9484 Node rhs,
9485 A arg) {
9486 return handleLocalCompounds(
9487 node,
9488 variable,
9489 new AssignmentCompound(operator, rhs),
9490 arg,
9491 isSetterValid: false); 6270 isSetterValid: false);
9492 } 6271 }
9493 6272
9494 @override 6273 @override
9495 R visitLocalFunctionCompound( 6274 R visitLocalFunctionCompound(Send node, LocalFunctionElement function,
9496 Send node, 6275 AssignmentOperator operator, Node rhs, A arg) {
9497 LocalFunctionElement function, 6276 return handleLocalCompounds(
9498 AssignmentOperator operator, 6277 node, function, new AssignmentCompound(operator, rhs), arg,
9499 Node rhs,
9500 A arg) {
9501 return handleLocalCompounds(
9502 node,
9503 function,
9504 new AssignmentCompound(operator, rhs),
9505 arg,
9506 isSetterValid: false); 6278 isSetterValid: false);
9507 } 6279 }
9508 6280
9509 @override 6281 @override
9510 R visitStaticFieldCompound( 6282 R visitStaticFieldCompound(Send node, FieldElement field,
9511 Send node, 6283 AssignmentOperator operator, Node rhs, A arg) {
9512 FieldElement field, 6284 return handleStaticCompounds(node, field, CompoundGetter.FIELD, field,
9513 AssignmentOperator operator, 6285 CompoundSetter.FIELD, new AssignmentCompound(operator, rhs), arg);
9514 Node rhs, 6286 }
9515 A arg) { 6287
9516 return handleStaticCompounds( 6288 @override
9517 node, 6289 R visitFinalStaticFieldCompound(Send node, FieldElement field,
9518 field, CompoundGetter.FIELD, 6290 AssignmentOperator operator, Node rhs, A arg) {
9519 field, CompoundSetter.FIELD, 6291 return handleStaticCompounds(node, field, CompoundGetter.FIELD, null,
9520 new AssignmentCompound(operator, rhs), 6292 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
9521 arg); 6293 }
9522 } 6294
9523 6295 @override
9524 @override 6296 R visitStaticGetterSetterCompound(Send node, FunctionElement getter,
9525 R visitFinalStaticFieldCompound( 6297 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
9526 Send node, 6298 return handleStaticCompounds(node, getter, CompoundGetter.GETTER, setter,
9527 FieldElement field, 6299 CompoundSetter.SETTER, new AssignmentCompound(operator, rhs), arg);
9528 AssignmentOperator operator, 6300 }
9529 Node rhs, 6301
9530 A arg) { 6302 @override
9531 return handleStaticCompounds( 6303 R visitStaticMethodSetterCompound(Send node, FunctionElement method,
9532 node, 6304 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
9533 field, CompoundGetter.FIELD, 6305 return handleStaticCompounds(node, method, CompoundGetter.METHOD, setter,
9534 null, CompoundSetter.INVALID, 6306 CompoundSetter.SETTER, new AssignmentCompound(operator, rhs), arg);
9535 new AssignmentCompound(operator, rhs), 6307 }
9536 arg); 6308
9537 } 6309 @override
9538 6310 R visitTopLevelFieldCompound(Send node, FieldElement field,
9539 @override 6311 AssignmentOperator operator, Node rhs, A arg) {
9540 R visitStaticGetterSetterCompound( 6312 return handleStaticCompounds(node, field, CompoundGetter.FIELD, field,
9541 Send node, 6313 CompoundSetter.FIELD, new AssignmentCompound(operator, rhs), arg);
9542 FunctionElement getter, 6314 }
9543 FunctionElement setter, 6315
9544 AssignmentOperator operator, 6316 @override
9545 Node rhs, 6317 R visitFinalTopLevelFieldCompound(Send node, FieldElement field,
9546 A arg) { 6318 AssignmentOperator operator, Node rhs, A arg) {
9547 return handleStaticCompounds( 6319 return handleStaticCompounds(node, field, CompoundGetter.FIELD, null,
9548 node, 6320 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
9549 getter, CompoundGetter.GETTER, 6321 }
9550 setter, CompoundSetter.SETTER, 6322
9551 new AssignmentCompound(operator, rhs), 6323 @override
9552 arg); 6324 R visitTopLevelGetterSetterCompound(Send node, FunctionElement getter,
9553 } 6325 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
9554 6326 return handleStaticCompounds(node, getter, CompoundGetter.GETTER, setter,
9555 @override 6327 CompoundSetter.SETTER, new AssignmentCompound(operator, rhs), arg);
9556 R visitStaticMethodSetterCompound( 6328 }
9557 Send node, 6329
9558 FunctionElement method, 6330 @override
9559 FunctionElement setter, 6331 R visitTopLevelMethodSetterCompound(Send node, FunctionElement method,
9560 AssignmentOperator operator, 6332 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
9561 Node rhs, 6333 return handleStaticCompounds(node, method, CompoundGetter.METHOD, setter,
9562 A arg) { 6334 CompoundSetter.SETTER, new AssignmentCompound(operator, rhs), arg);
9563 return handleStaticCompounds( 6335 }
9564 node, 6336
9565 method, CompoundGetter.METHOD, 6337 @override
9566 setter, CompoundSetter.SETTER, 6338 R visitSuperFieldCompound(Send node, FieldElement field,
9567 new AssignmentCompound(operator, rhs), 6339 AssignmentOperator operator, Node rhs, A arg) {
9568 arg); 6340 return handleSuperCompounds(node, field, CompoundGetter.FIELD, field,
9569 } 6341 CompoundSetter.FIELD, new AssignmentCompound(operator, rhs), arg);
9570 6342 }
9571 @override 6343
9572 R visitTopLevelFieldCompound( 6344 @override
9573 Send node, 6345 R visitFinalSuperFieldCompound(Send node, FieldElement field,
9574 FieldElement field, 6346 AssignmentOperator operator, Node rhs, A arg) {
9575 AssignmentOperator operator, 6347 return handleSuperCompounds(node, field, CompoundGetter.FIELD, field,
9576 Node rhs, 6348 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
9577 A arg) { 6349 }
9578 return handleStaticCompounds( 6350
9579 node, 6351 @override
9580 field, CompoundGetter.FIELD, 6352 R visitSuperGetterSetterCompound(Send node, FunctionElement getter,
9581 field, CompoundSetter.FIELD, 6353 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
9582 new AssignmentCompound(operator, rhs), 6354 return handleSuperCompounds(node, getter, CompoundGetter.GETTER, setter,
9583 arg); 6355 CompoundSetter.SETTER, new AssignmentCompound(operator, rhs), arg);
9584 } 6356 }
9585 6357
9586 @override 6358 @override
9587 R visitFinalTopLevelFieldCompound( 6359 R visitSuperMethodSetterCompound(Send node, FunctionElement method,
9588 Send node, 6360 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
9589 FieldElement field, 6361 return handleSuperCompounds(node, method, CompoundGetter.METHOD, setter,
9590 AssignmentOperator operator, 6362 CompoundSetter.SETTER, new AssignmentCompound(operator, rhs), arg);
9591 Node rhs, 6363 }
9592 A arg) { 6364
9593 return handleStaticCompounds( 6365 @override
9594 node, 6366 R visitSuperFieldSetterCompound(Send node, FieldElement field,
9595 field, CompoundGetter.FIELD, 6367 FunctionElement setter, AssignmentOperator operator, Node rhs, A arg) {
9596 null, CompoundSetter.INVALID, 6368 return handleSuperCompounds(node, field, CompoundGetter.FIELD, setter,
9597 new AssignmentCompound(operator, rhs), 6369 CompoundSetter.SETTER, new AssignmentCompound(operator, rhs), arg);
9598 arg); 6370 }
9599 } 6371
9600 6372 @override
9601 @override 6373 R visitSuperGetterFieldCompound(Send node, FunctionElement getter,
9602 R visitTopLevelGetterSetterCompound( 6374 FieldElement field, AssignmentOperator operator, Node rhs, A arg) {
9603 Send node, 6375 return handleSuperCompounds(node, getter, CompoundGetter.GETTER, field,
9604 FunctionElement getter, 6376 CompoundSetter.FIELD, new AssignmentCompound(operator, rhs), arg);
9605 FunctionElement setter, 6377 }
9606 AssignmentOperator operator, 6378
9607 Node rhs, 6379 @override
9608 A arg) { 6380 R visitClassTypeLiteralCompound(Send node, ConstantExpression constant,
9609 return handleStaticCompounds( 6381 AssignmentOperator operator, Node rhs, A arg) {
9610 node,
9611 getter, CompoundGetter.GETTER,
9612 setter, CompoundSetter.SETTER,
9613 new AssignmentCompound(operator, rhs),
9614 arg);
9615 }
9616
9617 @override
9618 R visitTopLevelMethodSetterCompound(
9619 Send node,
9620 FunctionElement method,
9621 FunctionElement setter,
9622 AssignmentOperator operator,
9623 Node rhs,
9624 A arg) {
9625 return handleStaticCompounds(
9626 node,
9627 method, CompoundGetter.METHOD,
9628 setter, CompoundSetter.SETTER,
9629 new AssignmentCompound(operator, rhs),
9630 arg);
9631 }
9632
9633 @override
9634 R visitSuperFieldCompound(
9635 Send node,
9636 FieldElement field,
9637 AssignmentOperator operator,
9638 Node rhs,
9639 A arg) {
9640 return handleSuperCompounds(
9641 node,
9642 field, CompoundGetter.FIELD,
9643 field, CompoundSetter.FIELD,
9644 new AssignmentCompound(operator, rhs),
9645 arg);
9646 }
9647
9648 @override
9649 R visitFinalSuperFieldCompound(
9650 Send node,
9651 FieldElement field,
9652 AssignmentOperator operator,
9653 Node rhs,
9654 A arg) {
9655 return handleSuperCompounds(
9656 node,
9657 field, CompoundGetter.FIELD,
9658 field, CompoundSetter.INVALID,
9659 new AssignmentCompound(operator, rhs),
9660 arg);
9661 }
9662
9663 @override
9664 R visitSuperGetterSetterCompound(
9665 Send node,
9666 FunctionElement getter,
9667 FunctionElement setter,
9668 AssignmentOperator operator,
9669 Node rhs,
9670 A arg) {
9671 return handleSuperCompounds(
9672 node,
9673 getter, CompoundGetter.GETTER,
9674 setter, CompoundSetter.SETTER,
9675 new AssignmentCompound(operator, rhs),
9676 arg);
9677 }
9678
9679 @override
9680 R visitSuperMethodSetterCompound(
9681 Send node,
9682 FunctionElement method,
9683 FunctionElement setter,
9684 AssignmentOperator operator,
9685 Node rhs,
9686 A arg) {
9687 return handleSuperCompounds(
9688 node,
9689 method, CompoundGetter.METHOD,
9690 setter, CompoundSetter.SETTER,
9691 new AssignmentCompound(operator, rhs),
9692 arg);
9693 }
9694
9695 @override
9696 R visitSuperFieldSetterCompound(
9697 Send node,
9698 FieldElement field,
9699 FunctionElement setter,
9700 AssignmentOperator operator,
9701 Node rhs,
9702 A arg) {
9703 return handleSuperCompounds(
9704 node,
9705 field, CompoundGetter.FIELD,
9706 setter, CompoundSetter.SETTER,
9707 new AssignmentCompound(operator, rhs),
9708 arg);
9709 }
9710
9711 @override
9712 R visitSuperGetterFieldCompound(
9713 Send node,
9714 FunctionElement getter,
9715 FieldElement field,
9716 AssignmentOperator operator,
9717 Node rhs,
9718 A arg) {
9719 return handleSuperCompounds(
9720 node,
9721 getter, CompoundGetter.GETTER,
9722 field, CompoundSetter.FIELD,
9723 new AssignmentCompound(operator, rhs),
9724 arg);
9725 }
9726
9727 @override
9728 R visitClassTypeLiteralCompound(
9729 Send node,
9730 ConstantExpression constant,
9731 AssignmentOperator operator,
9732 Node rhs,
9733 A arg) {
9734 return handleTypeLiteralConstantCompounds( 6382 return handleTypeLiteralConstantCompounds(
9735 node, 6383 node, constant, new AssignmentCompound(operator, rhs), arg);
9736 constant, 6384 }
9737 new AssignmentCompound(operator, rhs), 6385
9738 arg); 6386 @override
9739 } 6387 R visitTypedefTypeLiteralCompound(Send node, ConstantExpression constant,
9740 6388 AssignmentOperator operator, Node rhs, A arg) {
9741 @override
9742 R visitTypedefTypeLiteralCompound(
9743 Send node,
9744 ConstantExpression constant,
9745 AssignmentOperator operator,
9746 Node rhs,
9747 A arg) {
9748 return handleTypeLiteralConstantCompounds( 6389 return handleTypeLiteralConstantCompounds(
9749 node, 6390 node, constant, new AssignmentCompound(operator, rhs), arg);
9750 constant, 6391 }
9751 new AssignmentCompound(operator, rhs), 6392
9752 arg); 6393 @override
9753 } 6394 R visitTypeVariableTypeLiteralCompound(Send node, TypeVariableElement element,
9754 6395 AssignmentOperator operator, Node rhs, A arg) {
9755 @override
9756 R visitTypeVariableTypeLiteralCompound(
9757 Send node,
9758 TypeVariableElement element,
9759 AssignmentOperator operator,
9760 Node rhs,
9761 A arg) {
9762 return handleTypeVariableTypeLiteralCompounds( 6396 return handleTypeVariableTypeLiteralCompounds(
6397 node, element, new AssignmentCompound(operator, rhs), arg);
6398 }
6399
6400 @override
6401 R visitDynamicTypeLiteralCompound(Send node, ConstantExpression constant,
6402 AssignmentOperator operator, Node rhs, A arg) {
6403 return handleTypeLiteralConstantCompounds(
6404 node, constant, new AssignmentCompound(operator, rhs), arg);
6405 }
6406
6407 R visitDynamicPropertyPrefix(
6408 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
6409 return handleDynamicCompounds(node, receiver, name,
6410 new IncDecCompound(CompoundKind.PREFIX, operator), arg);
6411 }
6412
6413 R visitIfNotNullDynamicPropertyPrefix(
6414 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
6415 return handleDynamicCompounds(node, receiver, name,
6416 new IncDecCompound(CompoundKind.PREFIX, operator), arg);
6417 }
6418
6419 @override
6420 R visitParameterPrefix(
6421 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
6422 return handleLocalCompounds(
6423 node, parameter, new IncDecCompound(CompoundKind.PREFIX, operator), arg,
6424 isSetterValid: true);
6425 }
6426
6427 @override
6428 R visitLocalVariablePrefix(Send node, LocalVariableElement variable,
6429 IncDecOperator operator, A arg) {
6430 return handleLocalCompounds(
6431 node, variable, new IncDecCompound(CompoundKind.PREFIX, operator), arg,
6432 isSetterValid: true);
6433 }
6434
6435 @override
6436 R visitLocalFunctionPrefix(Send node, LocalFunctionElement function,
6437 IncDecOperator operator, A arg) {
6438 return handleLocalCompounds(
6439 node, function, new IncDecCompound(CompoundKind.PREFIX, operator), arg,
6440 isSetterValid: false);
6441 }
6442
6443 R visitThisPropertyPrefix(
6444 Send node, Name name, IncDecOperator operator, A arg) {
6445 return handleDynamicCompounds(node, null, name,
6446 new IncDecCompound(CompoundKind.PREFIX, operator), arg);
6447 }
6448
6449 @override
6450 R visitStaticFieldPrefix(
6451 Send node, FieldElement field, IncDecOperator operator, A arg) {
6452 return handleStaticCompounds(
6453 node,
6454 field,
6455 CompoundGetter.FIELD,
6456 field,
6457 CompoundSetter.FIELD,
6458 new IncDecCompound(CompoundKind.PREFIX, operator),
6459 arg);
6460 }
6461
6462 @override
6463 R visitStaticGetterSetterPrefix(Send node, FunctionElement getter,
6464 FunctionElement setter, IncDecOperator operator, A arg) {
6465 return handleStaticCompounds(
6466 node,
6467 getter,
6468 CompoundGetter.GETTER,
6469 setter,
6470 CompoundSetter.SETTER,
6471 new IncDecCompound(CompoundKind.PREFIX, operator),
6472 arg);
6473 }
6474
6475 R visitStaticMethodSetterPrefix(Send node, FunctionElement getter,
6476 FunctionElement setter, IncDecOperator operator, A arg) {
6477 return handleStaticCompounds(
6478 node,
6479 getter,
6480 CompoundGetter.METHOD,
6481 setter,
6482 CompoundSetter.SETTER,
6483 new IncDecCompound(CompoundKind.PREFIX, operator),
6484 arg);
6485 }
6486
6487 @override
6488 R visitTopLevelFieldPrefix(
6489 Send node, FieldElement field, IncDecOperator operator, A arg) {
6490 return handleStaticCompounds(
6491 node,
6492 field,
6493 CompoundGetter.FIELD,
6494 field,
6495 CompoundSetter.FIELD,
6496 new IncDecCompound(CompoundKind.PREFIX, operator),
6497 arg);
6498 }
6499
6500 @override
6501 R visitTopLevelGetterSetterPrefix(Send node, FunctionElement getter,
6502 FunctionElement setter, IncDecOperator operator, A arg) {
6503 return handleStaticCompounds(
6504 node,
6505 getter,
6506 CompoundGetter.GETTER,
6507 setter,
6508 CompoundSetter.SETTER,
6509 new IncDecCompound(CompoundKind.PREFIX, operator),
6510 arg);
6511 }
6512
6513 @override
6514 R visitTopLevelMethodSetterPrefix(Send node, FunctionElement method,
6515 FunctionElement setter, IncDecOperator operator, A arg) {
6516 return handleStaticCompounds(
6517 node,
6518 method,
6519 CompoundGetter.METHOD,
6520 setter,
6521 CompoundSetter.SETTER,
6522 new IncDecCompound(CompoundKind.PREFIX, operator),
6523 arg);
6524 }
6525
6526 @override
6527 R visitSuperFieldPrefix(
6528 Send node, FieldElement field, IncDecOperator operator, A arg) {
6529 return handleSuperCompounds(
6530 node,
6531 field,
6532 CompoundGetter.FIELD,
6533 field,
6534 CompoundSetter.FIELD,
6535 new IncDecCompound(CompoundKind.PREFIX, operator),
6536 arg);
6537 }
6538
6539 @override
6540 R visitSuperFieldFieldPrefix(Send node, FieldElement readField,
6541 FieldElement writtenField, IncDecOperator operator, A arg) {
6542 return handleSuperCompounds(
6543 node,
6544 readField,
6545 CompoundGetter.FIELD,
6546 writtenField,
6547 CompoundSetter.FIELD,
6548 new IncDecCompound(CompoundKind.PREFIX, operator),
6549 arg);
6550 }
6551
6552 @override
6553 R visitSuperFieldSetterPrefix(Send node, FieldElement field,
6554 FunctionElement setter, IncDecOperator operator, A arg) {
6555 return handleSuperCompounds(
6556 node,
6557 field,
6558 CompoundGetter.FIELD,
6559 setter,
6560 CompoundSetter.SETTER,
6561 new IncDecCompound(CompoundKind.PREFIX, operator),
6562 arg);
6563 }
6564
6565 @override
6566 R visitSuperGetterSetterPrefix(Send node, FunctionElement getter,
6567 FunctionElement setter, IncDecOperator operator, A arg) {
6568 return handleSuperCompounds(
6569 node,
6570 getter,
6571 CompoundGetter.GETTER,
6572 setter,
6573 CompoundSetter.SETTER,
6574 new IncDecCompound(CompoundKind.PREFIX, operator),
6575 arg);
6576 }
6577
6578 @override
6579 R visitSuperGetterFieldPrefix(Send node, FunctionElement getter,
6580 FieldElement field, IncDecOperator operator, A arg) {
6581 return handleSuperCompounds(
6582 node,
6583 getter,
6584 CompoundGetter.GETTER,
6585 field,
6586 CompoundSetter.FIELD,
6587 new IncDecCompound(CompoundKind.PREFIX, operator),
6588 arg);
6589 }
6590
6591 @override
6592 R visitSuperMethodSetterPrefix(Send node, FunctionElement method,
6593 FunctionElement setter, IncDecOperator operator, A arg) {
6594 return handleSuperCompounds(
6595 node,
6596 method,
6597 CompoundGetter.METHOD,
6598 setter,
6599 CompoundSetter.SETTER,
6600 new IncDecCompound(CompoundKind.PREFIX, operator),
6601 arg);
6602 }
6603
6604 @override
6605 R visitClassTypeLiteralPrefix(
6606 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
6607 return handleTypeLiteralConstantCompounds(
6608 node, constant, new IncDecCompound(CompoundKind.PREFIX, operator), arg);
6609 }
6610
6611 @override
6612 R visitTypedefTypeLiteralPrefix(
6613 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
6614 return handleTypeLiteralConstantCompounds(
6615 node, constant, new IncDecCompound(CompoundKind.PREFIX, operator), arg);
6616 }
6617
6618 @override
6619 R visitTypeVariableTypeLiteralPrefix(
6620 Send node, TypeVariableElement element, IncDecOperator operator, A arg) {
6621 return handleTypeVariableTypeLiteralCompounds(
6622 node, element, new IncDecCompound(CompoundKind.PREFIX, operator), arg);
6623 }
6624
6625 @override
6626 R visitDynamicTypeLiteralPrefix(
6627 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
6628 return handleTypeLiteralConstantCompounds(
6629 node, constant, new IncDecCompound(CompoundKind.PREFIX, operator), arg);
6630 }
6631
6632 @override
6633 R visitDynamicPropertyPostfix(
6634 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
6635 return handleDynamicCompounds(node, receiver, name,
6636 new IncDecCompound(CompoundKind.POSTFIX, operator), arg);
6637 }
6638
6639 @override
6640 R visitIfNotNullDynamicPropertyPostfix(
6641 Send node, Node receiver, Name name, IncDecOperator operator, A arg) {
6642 return handleDynamicCompounds(node, receiver, name,
6643 new IncDecCompound(CompoundKind.POSTFIX, operator), arg);
6644 }
6645
6646 @override
6647 R visitParameterPostfix(
6648 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
6649 return handleLocalCompounds(node, parameter,
6650 new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
6651 isSetterValid: true);
6652 }
6653
6654 @override
6655 R visitLocalVariablePostfix(Send node, LocalVariableElement variable,
6656 IncDecOperator operator, A arg) {
6657 return handleLocalCompounds(
6658 node, variable, new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
6659 isSetterValid: true);
6660 }
6661
6662 @override
6663 R visitLocalFunctionPostfix(Send node, LocalFunctionElement function,
6664 IncDecOperator operator, A arg) {
6665 return handleLocalCompounds(
6666 node, function, new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
6667 isSetterValid: false);
6668 }
6669
6670 R visitThisPropertyPostfix(
6671 Send node, Name name, IncDecOperator operator, A arg) {
6672 return handleDynamicCompounds(node, null, name,
6673 new IncDecCompound(CompoundKind.POSTFIX, operator), arg);
6674 }
6675
6676 @override
6677 R visitStaticFieldPostfix(
6678 Send node, FieldElement field, IncDecOperator operator, A arg) {
6679 return handleStaticCompounds(
6680 node,
6681 field,
6682 CompoundGetter.FIELD,
6683 field,
6684 CompoundSetter.FIELD,
6685 new IncDecCompound(CompoundKind.POSTFIX, operator),
6686 arg);
6687 }
6688
6689 @override
6690 R visitStaticGetterSetterPostfix(Send node, FunctionElement getter,
6691 FunctionElement setter, IncDecOperator operator, A arg) {
6692 return handleStaticCompounds(
6693 node,
6694 getter,
6695 CompoundGetter.GETTER,
6696 setter,
6697 CompoundSetter.SETTER,
6698 new IncDecCompound(CompoundKind.POSTFIX, operator),
6699 arg);
6700 }
6701
6702 R visitStaticMethodSetterPostfix(Send node, FunctionElement getter,
6703 FunctionElement setter, IncDecOperator operator, A arg) {
6704 return handleStaticCompounds(
6705 node,
6706 getter,
6707 CompoundGetter.METHOD,
6708 setter,
6709 CompoundSetter.SETTER,
6710 new IncDecCompound(CompoundKind.POSTFIX, operator),
6711 arg);
6712 }
6713
6714 @override
6715 R visitTopLevelFieldPostfix(
6716 Send node, FieldElement field, IncDecOperator operator, A arg) {
6717 return handleStaticCompounds(
6718 node,
6719 field,
6720 CompoundGetter.FIELD,
6721 field,
6722 CompoundSetter.FIELD,
6723 new IncDecCompound(CompoundKind.POSTFIX, operator),
6724 arg);
6725 }
6726
6727 @override
6728 R visitTopLevelGetterSetterPostfix(Send node, FunctionElement getter,
6729 FunctionElement setter, IncDecOperator operator, A arg) {
6730 return handleStaticCompounds(
6731 node,
6732 getter,
6733 CompoundGetter.GETTER,
6734 setter,
6735 CompoundSetter.SETTER,
6736 new IncDecCompound(CompoundKind.POSTFIX, operator),
6737 arg);
6738 }
6739
6740 @override
6741 R visitTopLevelMethodSetterPostfix(Send node, FunctionElement method,
6742 FunctionElement setter, IncDecOperator operator, A arg) {
6743 return handleStaticCompounds(
6744 node,
6745 method,
6746 CompoundGetter.METHOD,
6747 setter,
6748 CompoundSetter.SETTER,
6749 new IncDecCompound(CompoundKind.POSTFIX, operator),
6750 arg);
6751 }
6752
6753 @override
6754 R visitSuperFieldPostfix(
6755 Send node, FieldElement field, IncDecOperator operator, A arg) {
6756 return handleSuperCompounds(
6757 node,
6758 field,
6759 CompoundGetter.FIELD,
6760 field,
6761 CompoundSetter.FIELD,
6762 new IncDecCompound(CompoundKind.POSTFIX, operator),
6763 arg);
6764 }
6765
6766 @override
6767 R visitSuperFieldFieldPostfix(Send node, FieldElement readField,
6768 FieldElement writtenField, IncDecOperator operator, A arg) {
6769 return handleSuperCompounds(
6770 node,
6771 readField,
6772 CompoundGetter.FIELD,
6773 writtenField,
6774 CompoundSetter.FIELD,
6775 new IncDecCompound(CompoundKind.POSTFIX, operator),
6776 arg);
6777 }
6778
6779 @override
6780 R visitSuperFieldSetterPostfix(Send node, FieldElement field,
6781 FunctionElement setter, IncDecOperator operator, A arg) {
6782 return handleSuperCompounds(
6783 node,
6784 field,
6785 CompoundGetter.FIELD,
6786 setter,
6787 CompoundSetter.SETTER,
6788 new IncDecCompound(CompoundKind.POSTFIX, operator),
6789 arg);
6790 }
6791
6792 R visitSuperGetterSetterPostfix(Send node, FunctionElement getter,
6793 FunctionElement setter, IncDecOperator operator, A arg) {
6794 return handleSuperCompounds(
6795 node,
6796 getter,
6797 CompoundGetter.GETTER,
6798 setter,
6799 CompoundSetter.SETTER,
6800 new IncDecCompound(CompoundKind.POSTFIX, operator),
6801 arg);
6802 }
6803
6804 @override
6805 R visitSuperGetterFieldPostfix(Send node, FunctionElement getter,
6806 FieldElement field, IncDecOperator operator, A arg) {
6807 return handleSuperCompounds(
6808 node,
6809 getter,
6810 CompoundGetter.GETTER,
6811 field,
6812 CompoundSetter.FIELD,
6813 new IncDecCompound(CompoundKind.POSTFIX, operator),
6814 arg);
6815 }
6816
6817 @override
6818 R visitSuperMethodSetterPostfix(Send node, FunctionElement method,
6819 FunctionElement setter, IncDecOperator operator, A arg) {
6820 return handleSuperCompounds(
6821 node,
6822 method,
6823 CompoundGetter.METHOD,
6824 setter,
6825 CompoundSetter.SETTER,
6826 new IncDecCompound(CompoundKind.POSTFIX, operator),
6827 arg);
6828 }
6829
6830 @override
6831 R visitClassTypeLiteralPostfix(
6832 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
6833 return handleTypeLiteralConstantCompounds(node, constant,
6834 new IncDecCompound(CompoundKind.POSTFIX, operator), arg);
6835 }
6836
6837 @override
6838 R visitTypedefTypeLiteralPostfix(
6839 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
6840 return handleTypeLiteralConstantCompounds(node, constant,
6841 new IncDecCompound(CompoundKind.POSTFIX, operator), arg);
6842 }
6843
6844 @override
6845 R visitTypeVariableTypeLiteralPostfix(
6846 Send node, TypeVariableElement element, IncDecOperator operator, A arg) {
6847 return handleTypeVariableTypeLiteralCompounds(
6848 node, element, new IncDecCompound(CompoundKind.POSTFIX, operator), arg);
6849 }
6850
6851 @override
6852 R visitDynamicTypeLiteralPostfix(
6853 Send node, ConstantExpression constant, IncDecOperator operator, A arg) {
6854 return handleTypeLiteralConstantCompounds(node, constant,
6855 new IncDecCompound(CompoundKind.POSTFIX, operator), arg);
6856 }
6857
6858 @override
6859 R visitUnresolvedStaticGetterPostfix(Send node, Element element,
6860 MethodElement setter, IncDecOperator operator, A arg) {
6861 return handleStaticCompounds(
9763 node, 6862 node,
9764 element, 6863 element,
9765 new AssignmentCompound(operator, rhs),
9766 arg);
9767 }
9768
9769 @override
9770 R visitDynamicTypeLiteralCompound(
9771 Send node,
9772 ConstantExpression constant,
9773 AssignmentOperator operator,
9774 Node rhs,
9775 A arg) {
9776 return handleTypeLiteralConstantCompounds(
9777 node,
9778 constant,
9779 new AssignmentCompound(operator, rhs),
9780 arg);
9781 }
9782
9783
9784 R visitDynamicPropertyPrefix(
9785 Send node,
9786 Node receiver,
9787 Name name,
9788 IncDecOperator operator,
9789 A arg) {
9790 return handleDynamicCompounds(
9791 node,
9792 receiver,
9793 name,
9794 new IncDecCompound(CompoundKind.PREFIX, operator),
9795 arg);
9796 }
9797
9798 R visitIfNotNullDynamicPropertyPrefix(
9799 Send node,
9800 Node receiver,
9801 Name name,
9802 IncDecOperator operator,
9803 A arg) {
9804 return handleDynamicCompounds(
9805 node,
9806 receiver,
9807 name,
9808 new IncDecCompound(CompoundKind.PREFIX, operator),
9809 arg);
9810 }
9811
9812 @override
9813 R visitParameterPrefix(
9814 Send node,
9815 ParameterElement parameter,
9816 IncDecOperator operator,
9817 A arg) {
9818 return handleLocalCompounds(
9819 node,
9820 parameter,
9821 new IncDecCompound(CompoundKind.PREFIX, operator),
9822 arg,
9823 isSetterValid: true);
9824 }
9825
9826 @override
9827 R visitLocalVariablePrefix(
9828 Send node,
9829 LocalVariableElement variable,
9830 IncDecOperator operator,
9831 A arg) {
9832 return handleLocalCompounds(
9833 node,
9834 variable,
9835 new IncDecCompound(CompoundKind.PREFIX, operator),
9836 arg,
9837 isSetterValid: true);
9838 }
9839
9840 @override
9841 R visitLocalFunctionPrefix(
9842 Send node,
9843 LocalFunctionElement function,
9844 IncDecOperator operator,
9845 A arg) {
9846 return handleLocalCompounds(
9847 node,
9848 function,
9849 new IncDecCompound(CompoundKind.PREFIX, operator),
9850 arg,
9851 isSetterValid: false);
9852 }
9853
9854
9855 R visitThisPropertyPrefix(
9856 Send node,
9857 Name name,
9858 IncDecOperator operator,
9859 A arg) {
9860 return handleDynamicCompounds(
9861 node,
9862 null,
9863 name,
9864 new IncDecCompound(CompoundKind.PREFIX, operator),
9865 arg);
9866 }
9867
9868 @override
9869 R visitStaticFieldPrefix(
9870 Send node,
9871 FieldElement field,
9872 IncDecOperator operator,
9873 A arg) {
9874 return handleStaticCompounds(
9875 node,
9876 field, CompoundGetter.FIELD,
9877 field, CompoundSetter.FIELD,
9878 new IncDecCompound(CompoundKind.PREFIX, operator),
9879 arg);
9880 }
9881
9882 @override
9883 R visitStaticGetterSetterPrefix(
9884 Send node,
9885 FunctionElement getter,
9886 FunctionElement setter,
9887 IncDecOperator operator,
9888 A arg) {
9889 return handleStaticCompounds(
9890 node,
9891 getter, CompoundGetter.GETTER,
9892 setter, CompoundSetter.SETTER,
9893 new IncDecCompound(CompoundKind.PREFIX, operator),
9894 arg);
9895 }
9896
9897
9898 R visitStaticMethodSetterPrefix(
9899 Send node,
9900 FunctionElement getter,
9901 FunctionElement setter,
9902 IncDecOperator operator,
9903 A arg) {
9904 return handleStaticCompounds(
9905 node,
9906 getter, CompoundGetter.METHOD,
9907 setter, CompoundSetter.SETTER,
9908 new IncDecCompound(CompoundKind.PREFIX, operator),
9909 arg);
9910 }
9911
9912 @override
9913 R visitTopLevelFieldPrefix(
9914 Send node,
9915 FieldElement field,
9916 IncDecOperator operator,
9917 A arg) {
9918 return handleStaticCompounds(
9919 node,
9920 field, CompoundGetter.FIELD,
9921 field, CompoundSetter.FIELD,
9922 new IncDecCompound(CompoundKind.PREFIX, operator),
9923 arg);
9924 }
9925
9926 @override
9927 R visitTopLevelGetterSetterPrefix(
9928 Send node,
9929 FunctionElement getter,
9930 FunctionElement setter,
9931 IncDecOperator operator,
9932 A arg) {
9933 return handleStaticCompounds(
9934 node,
9935 getter, CompoundGetter.GETTER,
9936 setter, CompoundSetter.SETTER,
9937 new IncDecCompound(CompoundKind.PREFIX, operator),
9938 arg);
9939 }
9940
9941 @override
9942 R visitTopLevelMethodSetterPrefix(
9943 Send node,
9944 FunctionElement method,
9945 FunctionElement setter,
9946 IncDecOperator operator,
9947 A arg) {
9948 return handleStaticCompounds(
9949 node,
9950 method, CompoundGetter.METHOD,
9951 setter, CompoundSetter.SETTER,
9952 new IncDecCompound(CompoundKind.PREFIX, operator),
9953 arg);
9954 }
9955
9956 @override
9957 R visitSuperFieldPrefix(
9958 Send node,
9959 FieldElement field,
9960 IncDecOperator operator,
9961 A arg) {
9962 return handleSuperCompounds(
9963 node,
9964 field, CompoundGetter.FIELD,
9965 field, CompoundSetter.FIELD,
9966 new IncDecCompound(CompoundKind.PREFIX, operator),
9967 arg);
9968 }
9969
9970 @override
9971 R visitSuperFieldFieldPrefix(
9972 Send node,
9973 FieldElement readField,
9974 FieldElement writtenField,
9975 IncDecOperator operator,
9976 A arg) {
9977 return handleSuperCompounds(
9978 node,
9979 readField, CompoundGetter.FIELD,
9980 writtenField, CompoundSetter.FIELD,
9981 new IncDecCompound(CompoundKind.PREFIX, operator),
9982 arg);
9983 }
9984
9985 @override
9986 R visitSuperFieldSetterPrefix(
9987 Send node,
9988 FieldElement field,
9989 FunctionElement setter,
9990 IncDecOperator operator,
9991 A arg) {
9992 return handleSuperCompounds(
9993 node,
9994 field, CompoundGetter.FIELD,
9995 setter, CompoundSetter.SETTER,
9996 new IncDecCompound(CompoundKind.PREFIX, operator),
9997 arg);
9998 }
9999
10000 @override
10001 R visitSuperGetterSetterPrefix(
10002 Send node,
10003 FunctionElement getter,
10004 FunctionElement setter,
10005 IncDecOperator operator,
10006 A arg) {
10007 return handleSuperCompounds(
10008 node,
10009 getter, CompoundGetter.GETTER,
10010 setter, CompoundSetter.SETTER,
10011 new IncDecCompound(CompoundKind.PREFIX, operator),
10012 arg);
10013 }
10014
10015 @override
10016 R visitSuperGetterFieldPrefix(
10017 Send node,
10018 FunctionElement getter,
10019 FieldElement field,
10020 IncDecOperator operator,
10021 A arg) {
10022 return handleSuperCompounds(
10023 node,
10024 getter, CompoundGetter.GETTER,
10025 field, CompoundSetter.FIELD,
10026 new IncDecCompound(CompoundKind.PREFIX, operator),
10027 arg);
10028 }
10029
10030 @override
10031 R visitSuperMethodSetterPrefix(
10032 Send node,
10033 FunctionElement method,
10034 FunctionElement setter,
10035 IncDecOperator operator,
10036 A arg) {
10037 return handleSuperCompounds(
10038 node,
10039 method, CompoundGetter.METHOD,
10040 setter, CompoundSetter.SETTER,
10041 new IncDecCompound(CompoundKind.PREFIX, operator),
10042 arg);
10043 }
10044
10045 @override
10046 R visitClassTypeLiteralPrefix(
10047 Send node,
10048 ConstantExpression constant,
10049 IncDecOperator operator,
10050 A arg) {
10051 return handleTypeLiteralConstantCompounds(
10052 node,
10053 constant,
10054 new IncDecCompound(CompoundKind.PREFIX, operator),
10055 arg);
10056 }
10057
10058 @override
10059 R visitTypedefTypeLiteralPrefix(
10060 Send node,
10061 ConstantExpression constant,
10062 IncDecOperator operator,
10063 A arg) {
10064 return handleTypeLiteralConstantCompounds(
10065 node,
10066 constant,
10067 new IncDecCompound(CompoundKind.PREFIX, operator),
10068 arg);
10069 }
10070
10071 @override
10072 R visitTypeVariableTypeLiteralPrefix(
10073 Send node,
10074 TypeVariableElement element,
10075 IncDecOperator operator,
10076 A arg) {
10077 return handleTypeVariableTypeLiteralCompounds(
10078 node,
10079 element,
10080 new IncDecCompound(CompoundKind.PREFIX, operator),
10081 arg);
10082 }
10083
10084 @override
10085 R visitDynamicTypeLiteralPrefix(
10086 Send node,
10087 ConstantExpression constant,
10088 IncDecOperator operator,
10089 A arg) {
10090 return handleTypeLiteralConstantCompounds(
10091 node,
10092 constant,
10093 new IncDecCompound(CompoundKind.PREFIX, operator),
10094 arg);
10095 }
10096
10097 @override
10098 R visitDynamicPropertyPostfix(
10099 Send node,
10100 Node receiver,
10101 Name name,
10102 IncDecOperator operator,
10103 A arg) {
10104 return handleDynamicCompounds(
10105 node,
10106 receiver,
10107 name,
10108 new IncDecCompound(CompoundKind.POSTFIX, operator),
10109 arg);
10110 }
10111
10112 @override
10113 R visitIfNotNullDynamicPropertyPostfix(
10114 Send node,
10115 Node receiver,
10116 Name name,
10117 IncDecOperator operator,
10118 A arg) {
10119 return handleDynamicCompounds(
10120 node,
10121 receiver,
10122 name,
10123 new IncDecCompound(CompoundKind.POSTFIX, operator),
10124 arg);
10125 }
10126
10127 @override
10128 R visitParameterPostfix(
10129 Send node,
10130 ParameterElement parameter,
10131 IncDecOperator operator,
10132 A arg) {
10133 return handleLocalCompounds(
10134 node,
10135 parameter,
10136 new IncDecCompound(CompoundKind.POSTFIX, operator),
10137 arg,
10138 isSetterValid: true);
10139 }
10140
10141 @override
10142 R visitLocalVariablePostfix(
10143 Send node,
10144 LocalVariableElement variable,
10145 IncDecOperator operator,
10146 A arg) {
10147 return handleLocalCompounds(
10148 node,
10149 variable,
10150 new IncDecCompound(CompoundKind.POSTFIX, operator),
10151 arg,
10152 isSetterValid: true);
10153 }
10154
10155 @override
10156 R visitLocalFunctionPostfix(
10157 Send node,
10158 LocalFunctionElement function,
10159 IncDecOperator operator,
10160 A arg) {
10161 return handleLocalCompounds(
10162 node,
10163 function,
10164 new IncDecCompound(CompoundKind.POSTFIX, operator),
10165 arg,
10166 isSetterValid: false);
10167 }
10168
10169
10170 R visitThisPropertyPostfix(
10171 Send node,
10172 Name name,
10173 IncDecOperator operator,
10174 A arg) {
10175 return handleDynamicCompounds(
10176 node,
10177 null,
10178 name,
10179 new IncDecCompound(CompoundKind.POSTFIX, operator),
10180 arg);
10181 }
10182
10183 @override
10184 R visitStaticFieldPostfix(
10185 Send node,
10186 FieldElement field,
10187 IncDecOperator operator,
10188 A arg) {
10189 return handleStaticCompounds(
10190 node,
10191 field, CompoundGetter.FIELD,
10192 field, CompoundSetter.FIELD,
10193 new IncDecCompound(CompoundKind.POSTFIX, operator),
10194 arg);
10195 }
10196
10197 @override
10198 R visitStaticGetterSetterPostfix(
10199 Send node,
10200 FunctionElement getter,
10201 FunctionElement setter,
10202 IncDecOperator operator,
10203 A arg) {
10204 return handleStaticCompounds(
10205 node,
10206 getter, CompoundGetter.GETTER,
10207 setter, CompoundSetter.SETTER,
10208 new IncDecCompound(CompoundKind.POSTFIX, operator),
10209 arg);
10210 }
10211
10212
10213 R visitStaticMethodSetterPostfix(
10214 Send node,
10215 FunctionElement getter,
10216 FunctionElement setter,
10217 IncDecOperator operator,
10218 A arg) {
10219 return handleStaticCompounds(
10220 node,
10221 getter, CompoundGetter.METHOD,
10222 setter, CompoundSetter.SETTER,
10223 new IncDecCompound(CompoundKind.POSTFIX, operator),
10224 arg);
10225 }
10226
10227 @override
10228 R visitTopLevelFieldPostfix(
10229 Send node,
10230 FieldElement field,
10231 IncDecOperator operator,
10232 A arg) {
10233 return handleStaticCompounds(
10234 node,
10235 field, CompoundGetter.FIELD,
10236 field, CompoundSetter.FIELD,
10237 new IncDecCompound(CompoundKind.POSTFIX, operator),
10238 arg);
10239 }
10240
10241 @override
10242 R visitTopLevelGetterSetterPostfix(
10243 Send node,
10244 FunctionElement getter,
10245 FunctionElement setter,
10246 IncDecOperator operator,
10247 A arg) {
10248 return handleStaticCompounds(
10249 node,
10250 getter, CompoundGetter.GETTER,
10251 setter, CompoundSetter.SETTER,
10252 new IncDecCompound(CompoundKind.POSTFIX, operator),
10253 arg);
10254 }
10255
10256 @override
10257 R visitTopLevelMethodSetterPostfix(
10258 Send node,
10259 FunctionElement method,
10260 FunctionElement setter,
10261 IncDecOperator operator,
10262 A arg) {
10263 return handleStaticCompounds(
10264 node,
10265 method, CompoundGetter.METHOD,
10266 setter, CompoundSetter.SETTER,
10267 new IncDecCompound(CompoundKind.POSTFIX, operator),
10268 arg);
10269 }
10270
10271 @override
10272 R visitSuperFieldPostfix(
10273 Send node,
10274 FieldElement field,
10275 IncDecOperator operator,
10276 A arg) {
10277 return handleSuperCompounds(
10278 node,
10279 field, CompoundGetter.FIELD,
10280 field, CompoundSetter.FIELD,
10281 new IncDecCompound(CompoundKind.POSTFIX, operator),
10282 arg);
10283 }
10284
10285 @override
10286 R visitSuperFieldFieldPostfix(
10287 Send node,
10288 FieldElement readField,
10289 FieldElement writtenField,
10290 IncDecOperator operator,
10291 A arg) {
10292 return handleSuperCompounds(
10293 node,
10294 readField, CompoundGetter.FIELD,
10295 writtenField, CompoundSetter.FIELD,
10296 new IncDecCompound(CompoundKind.POSTFIX, operator),
10297 arg);
10298 }
10299
10300 @override
10301 R visitSuperFieldSetterPostfix(
10302 Send node,
10303 FieldElement field,
10304 FunctionElement setter,
10305 IncDecOperator operator,
10306 A arg) {
10307 return handleSuperCompounds(
10308 node,
10309 field, CompoundGetter.FIELD,
10310 setter, CompoundSetter.SETTER,
10311 new IncDecCompound(CompoundKind.POSTFIX, operator),
10312 arg);
10313 }
10314
10315
10316 R visitSuperGetterSetterPostfix(
10317 Send node,
10318 FunctionElement getter,
10319 FunctionElement setter,
10320 IncDecOperator operator,
10321 A arg) {
10322 return handleSuperCompounds(
10323 node,
10324 getter, CompoundGetter.GETTER,
10325 setter, CompoundSetter.SETTER,
10326 new IncDecCompound(CompoundKind.POSTFIX, operator),
10327 arg);
10328 }
10329
10330 @override
10331 R visitSuperGetterFieldPostfix(
10332 Send node,
10333 FunctionElement getter,
10334 FieldElement field,
10335 IncDecOperator operator,
10336 A arg) {
10337 return handleSuperCompounds(
10338 node,
10339 getter, CompoundGetter.GETTER,
10340 field, CompoundSetter.FIELD,
10341 new IncDecCompound(CompoundKind.POSTFIX, operator),
10342 arg);
10343 }
10344
10345 @override
10346 R visitSuperMethodSetterPostfix(
10347 Send node,
10348 FunctionElement method,
10349 FunctionElement setter,
10350 IncDecOperator operator,
10351 A arg) {
10352 return handleSuperCompounds(
10353 node,
10354 method, CompoundGetter.METHOD,
10355 setter, CompoundSetter.SETTER,
10356 new IncDecCompound(CompoundKind.POSTFIX, operator),
10357 arg);
10358 }
10359
10360 @override
10361 R visitClassTypeLiteralPostfix(
10362 Send node,
10363 ConstantExpression constant,
10364 IncDecOperator operator,
10365 A arg) {
10366 return handleTypeLiteralConstantCompounds(
10367 node,
10368 constant,
10369 new IncDecCompound(CompoundKind.POSTFIX, operator),
10370 arg);
10371 }
10372
10373 @override
10374 R visitTypedefTypeLiteralPostfix(
10375 Send node,
10376 ConstantExpression constant,
10377 IncDecOperator operator,
10378 A arg) {
10379 return handleTypeLiteralConstantCompounds(
10380 node,
10381 constant,
10382 new IncDecCompound(CompoundKind.POSTFIX, operator),
10383 arg);
10384 }
10385
10386 @override
10387 R visitTypeVariableTypeLiteralPostfix(
10388 Send node,
10389 TypeVariableElement element,
10390 IncDecOperator operator,
10391 A arg) {
10392 return handleTypeVariableTypeLiteralCompounds(
10393 node,
10394 element,
10395 new IncDecCompound(CompoundKind.POSTFIX, operator),
10396 arg);
10397 }
10398
10399 @override
10400 R visitDynamicTypeLiteralPostfix(
10401 Send node,
10402 ConstantExpression constant,
10403 IncDecOperator operator,
10404 A arg) {
10405 return handleTypeLiteralConstantCompounds(
10406 node,
10407 constant,
10408 new IncDecCompound(CompoundKind.POSTFIX, operator),
10409 arg);
10410 }
10411
10412 @override
10413 R visitUnresolvedStaticGetterPostfix(
10414 Send node,
10415 Element element,
10416 MethodElement setter,
10417 IncDecOperator operator,
10418 A arg) {
10419 return handleStaticCompounds(
10420 node,
10421 element,
10422 CompoundGetter.UNRESOLVED, 6864 CompoundGetter.UNRESOLVED,
10423 setter, 6865 setter,
10424 CompoundSetter.SETTER, 6866 CompoundSetter.SETTER,
10425 new IncDecCompound(CompoundKind.POSTFIX, operator), 6867 new IncDecCompound(CompoundKind.POSTFIX, operator),
10426 arg); 6868 arg);
10427 } 6869 }
10428 6870
10429 @override 6871 @override
10430 R visitUnresolvedTopLevelGetterPostfix( 6872 R visitUnresolvedTopLevelGetterPostfix(Send node, Element element,
10431 Send node, 6873 MethodElement setter, IncDecOperator operator, A arg) {
10432 Element element,
10433 MethodElement setter,
10434 IncDecOperator operator,
10435 A arg) {
10436 return handleStaticCompounds( 6874 return handleStaticCompounds(
10437 node, 6875 node,
10438 element, 6876 element,
10439 CompoundGetter.UNRESOLVED, 6877 CompoundGetter.UNRESOLVED,
10440 setter, 6878 setter,
10441 CompoundSetter.SETTER, 6879 CompoundSetter.SETTER,
10442 new IncDecCompound(CompoundKind.POSTFIX, operator), 6880 new IncDecCompound(CompoundKind.POSTFIX, operator),
10443 arg); 6881 arg);
10444 } 6882 }
10445 6883
10446 @override 6884 @override
10447 R visitUnresolvedStaticSetterPostfix( 6885 R visitUnresolvedStaticSetterPostfix(Send node, MethodElement getter,
10448 Send node, 6886 Element element, IncDecOperator operator, A arg) {
10449 MethodElement getter,
10450 Element element,
10451 IncDecOperator operator,
10452 A arg) {
10453 return handleStaticCompounds( 6887 return handleStaticCompounds(
10454 node, 6888 node,
10455 getter, 6889 getter,
10456 CompoundGetter.GETTER, 6890 CompoundGetter.GETTER,
10457 element, 6891 element,
10458 CompoundSetter.INVALID, 6892 CompoundSetter.INVALID,
10459 new IncDecCompound(CompoundKind.POSTFIX, operator), 6893 new IncDecCompound(CompoundKind.POSTFIX, operator),
10460 arg); 6894 arg);
10461 } 6895 }
10462 6896
10463 @override 6897 @override
10464 R visitUnresolvedTopLevelSetterPostfix( 6898 R visitUnresolvedTopLevelSetterPostfix(Send node, MethodElement getter,
10465 Send node, 6899 Element element, IncDecOperator operator, A arg) {
10466 MethodElement getter,
10467 Element element,
10468 IncDecOperator operator,
10469 A arg) {
10470 return handleStaticCompounds( 6900 return handleStaticCompounds(
10471 node, 6901 node,
10472 getter, 6902 getter,
10473 CompoundGetter.GETTER, 6903 CompoundGetter.GETTER,
10474 element, 6904 element,
10475 CompoundSetter.INVALID, 6905 CompoundSetter.INVALID,
10476 new IncDecCompound(CompoundKind.POSTFIX, operator), 6906 new IncDecCompound(CompoundKind.POSTFIX, operator),
10477 arg); 6907 arg);
10478 } 6908 }
10479 6909
10480 @override 6910 @override
10481 R visitStaticMethodPostfix( 6911 R visitStaticMethodPostfix(
10482 Send node, 6912 Send node, MethodElement method, IncDecOperator operator, A arg) {
10483 MethodElement method,
10484 IncDecOperator operator,
10485 A arg) {
10486 return handleStaticCompounds( 6913 return handleStaticCompounds(
10487 node, 6914 node,
10488 method, 6915 method,
10489 CompoundGetter.METHOD, 6916 CompoundGetter.METHOD,
10490 method, 6917 method,
10491 CompoundSetter.INVALID, 6918 CompoundSetter.INVALID,
10492 new IncDecCompound(CompoundKind.POSTFIX, operator), 6919 new IncDecCompound(CompoundKind.POSTFIX, operator),
10493 arg); 6920 arg);
10494 } 6921 }
10495 6922
10496 @override 6923 @override
10497 R visitTopLevelMethodPostfix( 6924 R visitTopLevelMethodPostfix(
10498 Send node, 6925 Send node, MethodElement method, IncDecOperator operator, A arg) {
10499 MethodElement method,
10500 IncDecOperator operator,
10501 A arg) {
10502 return handleStaticCompounds( 6926 return handleStaticCompounds(
10503 node, 6927 node,
10504 method, 6928 method,
10505 CompoundGetter.METHOD, 6929 CompoundGetter.METHOD,
10506 method, 6930 method,
10507 CompoundSetter.INVALID, 6931 CompoundSetter.INVALID,
10508 new IncDecCompound(CompoundKind.POSTFIX, operator), 6932 new IncDecCompound(CompoundKind.POSTFIX, operator),
10509 arg); 6933 arg);
10510 } 6934 }
10511 6935
10512 @override 6936 @override
10513 R visitUnresolvedPostfix( 6937 R visitUnresolvedPostfix(
10514 Send node, 6938 Send node, Element element, IncDecOperator operator, A arg) {
10515 Element element,
10516 IncDecOperator operator,
10517 A arg) {
10518 return handleStaticCompounds( 6939 return handleStaticCompounds(
10519 node, 6940 node,
10520 element, 6941 element,
10521 CompoundGetter.UNRESOLVED, 6942 CompoundGetter.UNRESOLVED,
10522 element, 6943 element,
10523 CompoundSetter.INVALID, 6944 CompoundSetter.INVALID,
10524 new IncDecCompound(CompoundKind.POSTFIX, operator), 6945 new IncDecCompound(CompoundKind.POSTFIX, operator),
10525 arg); 6946 arg);
10526 } 6947 }
10527 6948
10528 @override 6949 @override
10529 R visitUnresolvedStaticGetterPrefix( 6950 R visitUnresolvedStaticGetterPrefix(Send node, Element element,
10530 Send node, 6951 MethodElement setter, IncDecOperator operator, A arg) {
10531 Element element,
10532 MethodElement setter,
10533 IncDecOperator operator,
10534 A arg) {
10535 return handleStaticCompounds( 6952 return handleStaticCompounds(
10536 node, 6953 node,
10537 element, 6954 element,
10538 CompoundGetter.UNRESOLVED, 6955 CompoundGetter.UNRESOLVED,
10539 setter, 6956 setter,
10540 CompoundSetter.SETTER, 6957 CompoundSetter.SETTER,
10541 new IncDecCompound(CompoundKind.PREFIX, operator), 6958 new IncDecCompound(CompoundKind.PREFIX, operator),
10542 arg); 6959 arg);
10543 } 6960 }
10544 6961
10545 @override 6962 @override
10546 R visitUnresolvedTopLevelGetterPrefix( 6963 R visitUnresolvedTopLevelGetterPrefix(Send node, Element element,
10547 Send node, 6964 MethodElement setter, IncDecOperator operator, A arg) {
10548 Element element,
10549 MethodElement setter,
10550 IncDecOperator operator,
10551 A arg) {
10552 return handleStaticCompounds( 6965 return handleStaticCompounds(
10553 node, 6966 node,
10554 element, 6967 element,
10555 CompoundGetter.UNRESOLVED, 6968 CompoundGetter.UNRESOLVED,
10556 setter, 6969 setter,
10557 CompoundSetter.SETTER, 6970 CompoundSetter.SETTER,
10558 new IncDecCompound(CompoundKind.PREFIX, operator), 6971 new IncDecCompound(CompoundKind.PREFIX, operator),
10559 arg); 6972 arg);
10560 } 6973 }
10561 6974
10562 @override 6975 @override
10563 R visitUnresolvedStaticSetterPrefix( 6976 R visitUnresolvedStaticSetterPrefix(Send node, MethodElement getter,
10564 Send node, 6977 Element element, IncDecOperator operator, A arg) {
10565 MethodElement getter,
10566 Element element,
10567 IncDecOperator operator,
10568 A arg) {
10569 return handleStaticCompounds( 6978 return handleStaticCompounds(
10570 node, 6979 node,
10571 getter, 6980 getter,
10572 CompoundGetter.GETTER, 6981 CompoundGetter.GETTER,
10573 element, 6982 element,
10574 CompoundSetter.INVALID, 6983 CompoundSetter.INVALID,
10575 new IncDecCompound(CompoundKind.PREFIX, operator), 6984 new IncDecCompound(CompoundKind.PREFIX, operator),
10576 arg); 6985 arg);
10577 } 6986 }
10578 6987
10579 @override 6988 @override
10580 R visitUnresolvedTopLevelSetterPrefix( 6989 R visitUnresolvedTopLevelSetterPrefix(Send node, MethodElement getter,
10581 Send node, 6990 Element element, IncDecOperator operator, A arg) {
10582 MethodElement getter,
10583 Element element,
10584 IncDecOperator operator,
10585 A arg) {
10586 return handleStaticCompounds( 6991 return handleStaticCompounds(
10587 node, 6992 node,
10588 getter, 6993 getter,
10589 CompoundGetter.GETTER, 6994 CompoundGetter.GETTER,
10590 element, 6995 element,
10591 CompoundSetter.INVALID, 6996 CompoundSetter.INVALID,
10592 new IncDecCompound(CompoundKind.PREFIX, operator), 6997 new IncDecCompound(CompoundKind.PREFIX, operator),
10593 arg); 6998 arg);
10594 } 6999 }
10595 7000
10596 @override 7001 @override
10597 R visitStaticMethodPrefix( 7002 R visitStaticMethodPrefix(
10598 Send node, 7003 Send node, MethodElement method, IncDecOperator operator, A arg) {
10599 MethodElement method,
10600 IncDecOperator operator,
10601 A arg) {
10602 return handleStaticCompounds( 7004 return handleStaticCompounds(
10603 node, 7005 node,
10604 method, 7006 method,
10605 CompoundGetter.METHOD, 7007 CompoundGetter.METHOD,
10606 method, 7008 method,
10607 CompoundSetter.INVALID, 7009 CompoundSetter.INVALID,
10608 new IncDecCompound(CompoundKind.PREFIX, operator), 7010 new IncDecCompound(CompoundKind.PREFIX, operator),
10609 arg); 7011 arg);
10610 } 7012 }
10611 7013
10612 @override 7014 @override
10613 R visitTopLevelMethodPrefix( 7015 R visitTopLevelMethodPrefix(
10614 Send node, 7016 Send node, MethodElement method, IncDecOperator operator, A arg) {
10615 MethodElement method,
10616 IncDecOperator operator,
10617 A arg) {
10618 return handleStaticCompounds( 7017 return handleStaticCompounds(
10619 node, 7018 node,
10620 method, 7019 method,
10621 CompoundGetter.METHOD, 7020 CompoundGetter.METHOD,
10622 method, 7021 method,
10623 CompoundSetter.INVALID, 7022 CompoundSetter.INVALID,
10624 new IncDecCompound(CompoundKind.PREFIX, operator), 7023 new IncDecCompound(CompoundKind.PREFIX, operator),
10625 arg); 7024 arg);
10626 } 7025 }
10627 7026
10628 @override 7027 @override
10629 R visitUnresolvedPrefix( 7028 R visitUnresolvedPrefix(
10630 Send node, 7029 Send node, Element element, IncDecOperator operator, A arg) {
10631 Element element,
10632 IncDecOperator operator,
10633 A arg) {
10634 return handleStaticCompounds( 7030 return handleStaticCompounds(
10635 node, 7031 node,
10636 element, 7032 element,
10637 CompoundGetter.UNRESOLVED, 7033 CompoundGetter.UNRESOLVED,
10638 element, 7034 element,
10639 CompoundSetter.INVALID, 7035 CompoundSetter.INVALID,
10640 new IncDecCompound(CompoundKind.PREFIX, operator), 7036 new IncDecCompound(CompoundKind.PREFIX, operator),
10641 arg); 7037 arg);
10642 } 7038 }
10643 7039
10644 @override 7040 @override
10645 R visitUnresolvedStaticGetterCompound( 7041 R visitUnresolvedStaticGetterCompound(Send node, Element element,
10646 Send node, 7042 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
10647 Element element,
10648 MethodElement setter,
10649 AssignmentOperator operator,
10650 Node rhs,
10651 A arg) {
10652 return handleStaticCompounds( 7043 return handleStaticCompounds(
10653 node, 7044 node,
10654 element, 7045 element,
10655 CompoundGetter.UNRESOLVED, 7046 CompoundGetter.UNRESOLVED,
10656 setter, 7047 setter,
10657 CompoundSetter.SETTER, 7048 CompoundSetter.SETTER,
10658 new AssignmentCompound(operator, rhs), 7049 new AssignmentCompound(operator, rhs),
10659 arg); 7050 arg);
10660 } 7051 }
10661 7052
10662 @override 7053 @override
10663 R visitUnresolvedTopLevelGetterCompound( 7054 R visitUnresolvedTopLevelGetterCompound(Send node, Element element,
10664 Send node, 7055 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
10665 Element element,
10666 MethodElement setter,
10667 AssignmentOperator operator,
10668 Node rhs,
10669 A arg) {
10670 return handleStaticCompounds( 7056 return handleStaticCompounds(
10671 node, 7057 node,
10672 element, 7058 element,
10673 CompoundGetter.UNRESOLVED, 7059 CompoundGetter.UNRESOLVED,
10674 setter, 7060 setter,
10675 CompoundSetter.SETTER, 7061 CompoundSetter.SETTER,
10676 new AssignmentCompound(operator, rhs), 7062 new AssignmentCompound(operator, rhs),
10677 arg); 7063 arg);
10678 } 7064 }
10679 7065
10680 @override 7066 @override
10681 R visitUnresolvedStaticSetterCompound( 7067 R visitUnresolvedStaticSetterCompound(Send node, MethodElement getter,
10682 Send node, 7068 Element element, AssignmentOperator operator, Node rhs, A arg) {
10683 MethodElement getter, 7069 return handleStaticCompounds(node, getter, CompoundGetter.GETTER, element,
10684 Element element, 7070 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
10685 AssignmentOperator operator,
10686 Node rhs,
10687 A arg) {
10688 return handleStaticCompounds(
10689 node,
10690 getter,
10691 CompoundGetter.GETTER,
10692 element,
10693 CompoundSetter.INVALID,
10694 new AssignmentCompound(operator, rhs),
10695 arg);
10696 } 7071 }
10697 7072
10698 @override 7073 @override
10699 R visitUnresolvedTopLevelSetterCompound( 7074 R visitUnresolvedTopLevelSetterCompound(Send node, MethodElement getter,
10700 Send node, 7075 Element element, AssignmentOperator operator, Node rhs, A arg) {
10701 MethodElement getter, 7076 return handleStaticCompounds(node, getter, CompoundGetter.GETTER, element,
10702 Element element, 7077 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
10703 AssignmentOperator operator,
10704 Node rhs,
10705 A arg) {
10706 return handleStaticCompounds(
10707 node,
10708 getter,
10709 CompoundGetter.GETTER,
10710 element,
10711 CompoundSetter.INVALID,
10712 new AssignmentCompound(operator, rhs),
10713 arg);
10714 } 7078 }
10715 7079
10716 @override 7080 @override
10717 R visitStaticMethodCompound( 7081 R visitStaticMethodCompound(Send node, MethodElement method,
10718 Send node, 7082 AssignmentOperator operator, Node rhs, A arg) {
10719 MethodElement method, 7083 return handleStaticCompounds(node, method, CompoundGetter.METHOD, method,
10720 AssignmentOperator operator, 7084 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
10721 Node rhs,
10722 A arg) {
10723 return handleStaticCompounds(
10724 node,
10725 method,
10726 CompoundGetter.METHOD,
10727 method,
10728 CompoundSetter.INVALID,
10729 new AssignmentCompound(operator, rhs),
10730 arg);
10731 } 7085 }
10732 7086
10733 @override 7087 @override
10734 R visitTopLevelMethodCompound( 7088 R visitTopLevelMethodCompound(Send node, MethodElement method,
10735 Send node, 7089 AssignmentOperator operator, Node rhs, A arg) {
10736 MethodElement method, 7090 return handleStaticCompounds(node, method, CompoundGetter.METHOD, method,
10737 AssignmentOperator operator, 7091 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
10738 Node rhs,
10739 A arg) {
10740 return handleStaticCompounds(
10741 node,
10742 method,
10743 CompoundGetter.METHOD,
10744 method,
10745 CompoundSetter.INVALID,
10746 new AssignmentCompound(operator, rhs),
10747 arg);
10748 } 7092 }
10749 7093
10750 @override 7094 @override
10751 R visitUnresolvedCompound( 7095 R visitUnresolvedCompound(Send node, Element element,
10752 Send node, 7096 AssignmentOperator operator, Node rhs, A arg) {
10753 Element element,
10754 AssignmentOperator operator,
10755 Node rhs,
10756 A arg) {
10757 return handleStaticCompounds( 7097 return handleStaticCompounds(
10758 node, 7098 node,
10759 element, 7099 element,
10760 CompoundGetter.UNRESOLVED, 7100 CompoundGetter.UNRESOLVED,
10761 element, 7101 element,
10762 CompoundSetter.INVALID, 7102 CompoundSetter.INVALID,
10763 new AssignmentCompound(operator, rhs), 7103 new AssignmentCompound(operator, rhs),
10764 arg); 7104 arg);
10765 } 7105 }
10766 7106
10767 @override 7107 @override
10768 R visitFinalLocalVariablePostfix( 7108 R visitFinalLocalVariablePostfix(Send node, LocalVariableElement variable,
10769 Send node, 7109 IncDecOperator operator, A arg) {
10770 LocalVariableElement variable,
10771 IncDecOperator operator,
10772 A arg) {
10773 return handleLocalCompounds( 7110 return handleLocalCompounds(
10774 node, 7111 node, variable, new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
10775 variable,
10776 new IncDecCompound(CompoundKind.POSTFIX, operator),
10777 arg,
10778 isSetterValid: false); 7112 isSetterValid: false);
10779 } 7113 }
10780 7114
10781 @override 7115 @override
10782 R visitFinalLocalVariablePrefix( 7116 R visitFinalLocalVariablePrefix(Send node, LocalVariableElement variable,
10783 Send node, 7117 IncDecOperator operator, A arg) {
10784 LocalVariableElement variable,
10785 IncDecOperator operator,
10786 A arg) {
10787 return handleLocalCompounds( 7118 return handleLocalCompounds(
10788 node, 7119 node, variable, new IncDecCompound(CompoundKind.PREFIX, operator), arg,
10789 variable,
10790 new IncDecCompound(CompoundKind.PREFIX, operator),
10791 arg,
10792 isSetterValid: false); 7120 isSetterValid: false);
10793 } 7121 }
10794 7122
10795 @override 7123 @override
10796 R visitFinalParameterPostfix( 7124 R visitFinalParameterPostfix(
10797 Send node, 7125 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
10798 ParameterElement parameter, 7126 return handleLocalCompounds(node, parameter,
10799 IncDecOperator operator, 7127 new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
10800 A arg) {
10801 return handleLocalCompounds(
10802 node,
10803 parameter,
10804 new IncDecCompound(CompoundKind.POSTFIX, operator),
10805 arg,
10806 isSetterValid: false); 7128 isSetterValid: false);
10807 } 7129 }
10808 7130
10809 @override 7131 @override
10810 R visitFinalParameterPrefix( 7132 R visitFinalParameterPrefix(
10811 Send node, 7133 Send node, ParameterElement parameter, IncDecOperator operator, A arg) {
10812 ParameterElement parameter,
10813 IncDecOperator operator,
10814 A arg) {
10815 return handleLocalCompounds( 7134 return handleLocalCompounds(
10816 node, 7135 node, parameter, new IncDecCompound(CompoundKind.PREFIX, operator), arg,
10817 parameter,
10818 new IncDecCompound(CompoundKind.PREFIX, operator),
10819 arg,
10820 isSetterValid: false); 7136 isSetterValid: false);
10821 } 7137 }
10822 7138
10823 @override 7139 @override
10824 R visitFinalStaticFieldPostfix( 7140 R visitFinalStaticFieldPostfix(
10825 Send node, 7141 Send node, FieldElement field, IncDecOperator operator, A arg) {
10826 FieldElement field,
10827 IncDecOperator operator,
10828 A arg) {
10829 return handleStaticCompounds( 7142 return handleStaticCompounds(
10830 node, 7143 node,
10831 field, 7144 field,
10832 CompoundGetter.FIELD, 7145 CompoundGetter.FIELD,
10833 field, 7146 field,
10834 CompoundSetter.INVALID, 7147 CompoundSetter.INVALID,
10835 new IncDecCompound(CompoundKind.POSTFIX, operator), 7148 new IncDecCompound(CompoundKind.POSTFIX, operator),
10836 arg); 7149 arg);
10837 } 7150 }
10838 7151
10839 @override 7152 @override
10840 R visitFinalStaticFieldPrefix( 7153 R visitFinalStaticFieldPrefix(
10841 Send node, 7154 Send node, FieldElement field, IncDecOperator operator, A arg) {
10842 FieldElement field,
10843 IncDecOperator operator,
10844 A arg) {
10845 return handleStaticCompounds( 7155 return handleStaticCompounds(
10846 node, 7156 node,
10847 field, 7157 field,
10848 CompoundGetter.FIELD, 7158 CompoundGetter.FIELD,
10849 field, 7159 field,
10850 CompoundSetter.INVALID, 7160 CompoundSetter.INVALID,
10851 new IncDecCompound(CompoundKind.PREFIX, operator), 7161 new IncDecCompound(CompoundKind.PREFIX, operator),
10852 arg); 7162 arg);
10853 } 7163 }
10854 7164
10855 @override 7165 @override
10856 R visitSuperFieldFieldCompound( 7166 R visitSuperFieldFieldCompound(Send node, FieldElement readField,
10857 Send node, 7167 FieldElement writtenField, AssignmentOperator operator, Node rhs, A arg) {
10858 FieldElement readField,
10859 FieldElement writtenField,
10860 AssignmentOperator operator,
10861 Node rhs,
10862 A arg) {
10863 return handleSuperCompounds( 7168 return handleSuperCompounds(
10864 node, 7169 node,
10865 readField, 7170 readField,
10866 CompoundGetter.FIELD, 7171 CompoundGetter.FIELD,
10867 writtenField, 7172 writtenField,
10868 CompoundSetter.FIELD, 7173 CompoundSetter.FIELD,
10869 new AssignmentCompound(operator, rhs), 7174 new AssignmentCompound(operator, rhs),
10870 arg); 7175 arg);
10871 } 7176 }
10872 7177
10873 @override 7178 @override
10874 R visitFinalSuperFieldPostfix( 7179 R visitFinalSuperFieldPostfix(
10875 Send node, 7180 Send node, FieldElement field, IncDecOperator operator, A arg) {
10876 FieldElement field,
10877 IncDecOperator operator,
10878 A arg) {
10879 return handleSuperCompounds( 7181 return handleSuperCompounds(
10880 node, 7182 node,
10881 field, 7183 field,
10882 CompoundGetter.FIELD, 7184 CompoundGetter.FIELD,
10883 field, 7185 field,
10884 CompoundSetter.INVALID, 7186 CompoundSetter.INVALID,
10885 new IncDecCompound(CompoundKind.POSTFIX, operator), 7187 new IncDecCompound(CompoundKind.POSTFIX, operator),
10886 arg); 7188 arg);
10887 } 7189 }
10888 7190
10889 @override 7191 @override
10890 R visitFinalSuperFieldPrefix( 7192 R visitFinalSuperFieldPrefix(
10891 Send node, 7193 Send node, FieldElement field, IncDecOperator operator, A arg) {
10892 FieldElement field,
10893 IncDecOperator operator,
10894 A arg) {
10895 return handleSuperCompounds( 7194 return handleSuperCompounds(
10896 node, 7195 node,
10897 field, 7196 field,
10898 CompoundGetter.FIELD, 7197 CompoundGetter.FIELD,
10899 field, 7198 field,
10900 CompoundSetter.INVALID, 7199 CompoundSetter.INVALID,
10901 new IncDecCompound(CompoundKind.PREFIX, operator), 7200 new IncDecCompound(CompoundKind.PREFIX, operator),
10902 arg); 7201 arg);
10903 } 7202 }
10904 7203
10905 @override 7204 @override
10906 R visitSuperMethodCompound( 7205 R visitSuperMethodCompound(Send node, FunctionElement method,
10907 Send node, 7206 AssignmentOperator operator, Node rhs, A arg) {
10908 FunctionElement method, 7207 return handleSuperCompounds(node, method, CompoundGetter.METHOD, method,
10909 AssignmentOperator operator, 7208 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
10910 Node rhs,
10911 A arg) {
10912 return handleSuperCompounds(
10913 node,
10914 method,
10915 CompoundGetter.METHOD,
10916 method,
10917 CompoundSetter.INVALID,
10918 new AssignmentCompound(operator, rhs),
10919 arg);
10920 } 7209 }
10921 7210
10922 @override 7211 @override
10923 R visitSuperMethodPostfix( 7212 R visitSuperMethodPostfix(
10924 Send node, 7213 Send node, FunctionElement method, IncDecOperator operator, A arg) {
10925 FunctionElement method,
10926 IncDecOperator operator,
10927 A arg) {
10928 return handleSuperCompounds( 7214 return handleSuperCompounds(
10929 node, 7215 node,
10930 method, 7216 method,
10931 CompoundGetter.METHOD, 7217 CompoundGetter.METHOD,
10932 method, 7218 method,
10933 CompoundSetter.INVALID, 7219 CompoundSetter.INVALID,
10934 new IncDecCompound(CompoundKind.POSTFIX, operator), 7220 new IncDecCompound(CompoundKind.POSTFIX, operator),
10935 arg); 7221 arg);
10936 } 7222 }
10937 7223
10938 @override 7224 @override
10939 R visitSuperMethodPrefix( 7225 R visitSuperMethodPrefix(
10940 Send node, 7226 Send node, FunctionElement method, IncDecOperator operator, A arg) {
10941 FunctionElement method,
10942 IncDecOperator operator,
10943 A arg) {
10944 return handleSuperCompounds( 7227 return handleSuperCompounds(
10945 node, 7228 node,
10946 method, 7229 method,
10947 CompoundGetter.METHOD, 7230 CompoundGetter.METHOD,
10948 method, 7231 method,
10949 CompoundSetter.INVALID, 7232 CompoundSetter.INVALID,
10950 new IncDecCompound(CompoundKind.PREFIX, operator), 7233 new IncDecCompound(CompoundKind.PREFIX, operator),
10951 arg); 7234 arg);
10952 } 7235 }
10953 7236
10954 @override 7237 @override
10955 R visitFinalTopLevelFieldPostfix( 7238 R visitFinalTopLevelFieldPostfix(
10956 Send node, 7239 Send node, FieldElement field, IncDecOperator operator, A arg) {
10957 FieldElement field,
10958 IncDecOperator operator,
10959 A arg) {
10960 return handleStaticCompounds( 7240 return handleStaticCompounds(
10961 node, 7241 node,
10962 field, 7242 field,
10963 CompoundGetter.FIELD, 7243 CompoundGetter.FIELD,
10964 field, 7244 field,
10965 CompoundSetter.INVALID, 7245 CompoundSetter.INVALID,
10966 new IncDecCompound(CompoundKind.POSTFIX, operator), 7246 new IncDecCompound(CompoundKind.POSTFIX, operator),
10967 arg); 7247 arg);
10968 } 7248 }
10969 7249
10970 @override 7250 @override
10971 R visitFinalTopLevelFieldPrefix( 7251 R visitFinalTopLevelFieldPrefix(
10972 Send node, 7252 Send node, FieldElement field, IncDecOperator operator, A arg) {
10973 FieldElement field,
10974 IncDecOperator operator,
10975 A arg) {
10976 return handleStaticCompounds( 7253 return handleStaticCompounds(
10977 node, 7254 node,
10978 field, 7255 field,
10979 CompoundGetter.FIELD, 7256 CompoundGetter.FIELD,
10980 field, 7257 field,
10981 CompoundSetter.INVALID, 7258 CompoundSetter.INVALID,
10982 new IncDecCompound(CompoundKind.PREFIX, operator), 7259 new IncDecCompound(CompoundKind.PREFIX, operator),
10983 arg); 7260 arg);
10984 } 7261 }
10985 7262
10986 @override 7263 @override
10987 R visitUnresolvedSuperCompound( 7264 R visitUnresolvedSuperCompound(Send node, Element element,
10988 Send node, 7265 AssignmentOperator operator, Node rhs, A arg) {
10989 Element element,
10990 AssignmentOperator operator,
10991 Node rhs,
10992 A arg) {
10993 return handleSuperCompounds( 7266 return handleSuperCompounds(
10994 node, 7267 node,
10995 element, 7268 element,
10996 CompoundGetter.UNRESOLVED, 7269 CompoundGetter.UNRESOLVED,
10997 element, 7270 element,
10998 CompoundSetter.INVALID, 7271 CompoundSetter.INVALID,
10999 new AssignmentCompound(operator, rhs), 7272 new AssignmentCompound(operator, rhs),
11000 arg); 7273 arg);
11001 } 7274 }
11002 7275
11003 @override 7276 @override
11004 R visitUnresolvedSuperPostfix( 7277 R visitUnresolvedSuperPostfix(
11005 Send node, 7278 Send node, Element element, IncDecOperator operator, A arg) {
11006 Element element,
11007 IncDecOperator operator,
11008 A arg) {
11009 return handleSuperCompounds( 7279 return handleSuperCompounds(
11010 node, 7280 node,
11011 element, 7281 element,
11012 CompoundGetter.UNRESOLVED, 7282 CompoundGetter.UNRESOLVED,
11013 element, 7283 element,
11014 CompoundSetter.INVALID, 7284 CompoundSetter.INVALID,
11015 new IncDecCompound(CompoundKind.POSTFIX, operator), 7285 new IncDecCompound(CompoundKind.POSTFIX, operator),
11016 arg); 7286 arg);
11017 } 7287 }
11018 7288
11019 @override 7289 @override
11020 R visitUnresolvedSuperPrefix( 7290 R visitUnresolvedSuperPrefix(
11021 Send node, 7291 Send node, Element element, IncDecOperator operator, A arg) {
11022 Element element,
11023 IncDecOperator operator,
11024 A arg) {
11025 return handleSuperCompounds( 7292 return handleSuperCompounds(
11026 node, 7293 node,
11027 element, 7294 element,
11028 CompoundGetter.UNRESOLVED, 7295 CompoundGetter.UNRESOLVED,
11029 element, 7296 element,
11030 CompoundSetter.INVALID, 7297 CompoundSetter.INVALID,
11031 new IncDecCompound(CompoundKind.PREFIX, operator), 7298 new IncDecCompound(CompoundKind.PREFIX, operator),
11032 arg); 7299 arg);
11033 } 7300 }
11034 7301
11035 @override 7302 @override
11036 R visitUnresolvedSuperGetterCompound( 7303 R visitUnresolvedSuperGetterCompound(Send node, Element element,
11037 Send node, Element element, 7304 MethodElement setter, AssignmentOperator operator, Node rhs, A arg) {
11038 MethodElement setter,
11039 AssignmentOperator operator,
11040 Node rhs,
11041 A arg) {
11042 return handleSuperCompounds( 7305 return handleSuperCompounds(
11043 node, 7306 node,
11044 element, 7307 element,
11045 CompoundGetter.UNRESOLVED, 7308 CompoundGetter.UNRESOLVED,
11046 setter, 7309 setter,
11047 CompoundSetter.SETTER, 7310 CompoundSetter.SETTER,
11048 new AssignmentCompound(operator, rhs), 7311 new AssignmentCompound(operator, rhs),
11049 arg); 7312 arg);
11050 } 7313 }
11051 7314
11052 @override 7315 @override
11053 R visitUnresolvedSuperGetterPostfix( 7316 R visitUnresolvedSuperGetterPostfix(Send node, Element element,
11054 Send node, 7317 MethodElement setter, IncDecOperator operator, A arg) {
11055 Element element,
11056 MethodElement setter,
11057 IncDecOperator operator,
11058 A arg) {
11059 return handleSuperCompounds( 7318 return handleSuperCompounds(
11060 node, 7319 node,
11061 element, 7320 element,
11062 CompoundGetter.UNRESOLVED, 7321 CompoundGetter.UNRESOLVED,
11063 setter, 7322 setter,
11064 CompoundSetter.SETTER, 7323 CompoundSetter.SETTER,
11065 new IncDecCompound(CompoundKind.POSTFIX, operator), 7324 new IncDecCompound(CompoundKind.POSTFIX, operator),
11066 arg); 7325 arg);
11067 } 7326 }
11068 7327
11069 @override 7328 @override
11070 R visitUnresolvedSuperGetterPrefix( 7329 R visitUnresolvedSuperGetterPrefix(Send node, Element element,
11071 Send node, 7330 MethodElement setter, IncDecOperator operator, A arg) {
11072 Element element,
11073 MethodElement setter,
11074 IncDecOperator operator,
11075 A arg) {
11076 return handleSuperCompounds( 7331 return handleSuperCompounds(
11077 node, 7332 node,
11078 element, 7333 element,
11079 CompoundGetter.UNRESOLVED, 7334 CompoundGetter.UNRESOLVED,
11080 setter, 7335 setter,
11081 CompoundSetter.SETTER, 7336 CompoundSetter.SETTER,
11082 new IncDecCompound(CompoundKind.PREFIX, operator), 7337 new IncDecCompound(CompoundKind.PREFIX, operator),
11083 arg); 7338 arg);
11084 } 7339 }
11085 7340
11086 @override 7341 @override
11087 R visitUnresolvedSuperSetterCompound( 7342 R visitUnresolvedSuperSetterCompound(Send node, MethodElement getter,
11088 Send node, 7343 Element element, AssignmentOperator operator, Node rhs, A arg) {
11089 MethodElement getter, 7344 return handleSuperCompounds(node, getter, CompoundGetter.GETTER, element,
11090 Element element, 7345 CompoundSetter.INVALID, new AssignmentCompound(operator, rhs), arg);
11091 AssignmentOperator operator, 7346 }
11092 Node rhs, 7347
11093 A arg) { 7348 @override
7349 R visitUnresolvedSuperSetterPostfix(Send node, MethodElement getter,
7350 Element element, IncDecOperator operator, A arg) {
11094 return handleSuperCompounds( 7351 return handleSuperCompounds(
11095 node, 7352 node,
11096 getter, 7353 getter,
11097 CompoundGetter.GETTER,
11098 element,
11099 CompoundSetter.INVALID,
11100 new AssignmentCompound(operator, rhs),
11101 arg);
11102 }
11103
11104 @override
11105 R visitUnresolvedSuperSetterPostfix(
11106 Send node,
11107 MethodElement getter,
11108 Element element,
11109 IncDecOperator operator,
11110 A arg) {
11111 return handleSuperCompounds(
11112 node,
11113 getter,
11114 CompoundGetter.GETTER, 7354 CompoundGetter.GETTER,
11115 element, 7355 element,
11116 CompoundSetter.INVALID, 7356 CompoundSetter.INVALID,
11117 new IncDecCompound(CompoundKind.POSTFIX, operator), 7357 new IncDecCompound(CompoundKind.POSTFIX, operator),
11118 arg); 7358 arg);
11119 } 7359 }
11120 7360
11121 @override 7361 @override
11122 R visitUnresolvedSuperSetterPrefix( 7362 R visitUnresolvedSuperSetterPrefix(Send node, MethodElement getter,
11123 Send node, 7363 Element element, IncDecOperator operator, A arg) {
11124 MethodElement getter,
11125 Element element,
11126 IncDecOperator operator,
11127 A arg) {
11128 return handleSuperCompounds( 7364 return handleSuperCompounds(
11129 node, 7365 node,
11130 getter, 7366 getter,
11131 CompoundGetter.GETTER, 7367 CompoundGetter.GETTER,
11132 element, 7368 element,
11133 CompoundSetter.INVALID, 7369 CompoundSetter.INVALID,
11134 new IncDecCompound(CompoundKind.PREFIX, operator), 7370 new IncDecCompound(CompoundKind.PREFIX, operator),
11135 arg); 7371 arg);
11136 } 7372 }
11137 } 7373 }
11138 7374
11139 /// Simplified handling of if-null assignments. 7375 /// Simplified handling of if-null assignments.
11140 abstract class BaseImplementationOfSetIfNullsMixin<R, A> 7376 abstract class BaseImplementationOfSetIfNullsMixin<R, A>
11141 implements SemanticSendVisitor<R, A> { 7377 implements SemanticSendVisitor<R, A> {
11142
11143 /// Handle a super if-null assignments, like `super.foo ??= 42`. 7378 /// Handle a super if-null assignments, like `super.foo ??= 42`.
11144 R handleSuperSetIfNulls( 7379 R handleSuperSetIfNulls(
11145 SendSet node, 7380 SendSet node,
11146 Element getter, 7381 Element getter,
11147 CompoundGetter getterKind, 7382 CompoundGetter getterKind,
11148 Element setter, 7383 Element setter,
11149 CompoundSetter setterKind, 7384 CompoundSetter setterKind,
11150 Node rhs, 7385 Node rhs,
11151 A arg); 7386 A arg);
11152 7387
11153 /// Handle a static or top level if-null assignments, like `foo ??= 42`. 7388 /// Handle a static or top level if-null assignments, like `foo ??= 42`.
11154 R handleStaticSetIfNulls( 7389 R handleStaticSetIfNulls(
11155 SendSet node, 7390 SendSet node,
11156 Element getter, 7391 Element getter,
11157 CompoundGetter getterKind, 7392 CompoundGetter getterKind,
11158 Element setter, 7393 Element setter,
11159 CompoundSetter setterKind, 7394 CompoundSetter setterKind,
11160 Node rhs, 7395 Node rhs,
11161 A arg); 7396 A arg);
11162 7397
11163 /// Handle a local if-null assignments, like `foo ??= 42`. If [isSetterValid] 7398 /// Handle a local if-null assignments, like `foo ??= 42`. If [isSetterValid]
11164 /// is false [local] is unassignable. 7399 /// is false [local] is unassignable.
11165 R handleLocalSetIfNulls( 7400 R handleLocalSetIfNulls(SendSet node, LocalElement local, Node rhs, A arg,
11166 SendSet node,
11167 LocalElement local,
11168 Node rhs,
11169 A arg,
11170 {bool isSetterValid}); 7401 {bool isSetterValid});
11171 7402
11172 /// Handle a if-null assignments on a type literal constant, like 7403 /// Handle a if-null assignments on a type literal constant, like
11173 /// `Object ??= 42`. 7404 /// `Object ??= 42`.
11174 R handleTypeLiteralConstantSetIfNulls( 7405 R handleTypeLiteralConstantSetIfNulls(
11175 SendSet node, 7406 SendSet node, ConstantExpression constant, Node rhs, A arg);
11176 ConstantExpression constant,
11177 Node rhs,
11178 A arg);
11179 7407
11180 /// Handle a dynamic if-null assignments, like `o.foo ??= 42`. [receiver] is 7408 /// Handle a dynamic if-null assignments, like `o.foo ??= 42`. [receiver] is
11181 /// `null` for properties on `this`, like `this.foo ??= 42` or `foo ??= 42`. 7409 /// `null` for properties on `this`, like `this.foo ??= 42` or `foo ??= 42`.
11182 R handleDynamicSetIfNulls( 7410 R handleDynamicSetIfNulls(
11183 Send node, 7411 Send node, Node receiver, Name name, Node rhs, A arg);
11184 Node receiver,
11185 Name name,
11186 Node rhs,
11187 A arg);
11188 7412
11189 @override 7413 @override
11190 R visitClassTypeLiteralSetIfNull( 7414 R visitClassTypeLiteralSetIfNull(
11191 Send node, 7415 Send node, ConstantExpression constant, Node rhs, A arg) {
11192 ConstantExpression constant,
11193 Node rhs,
11194 A arg) {
11195 return handleTypeLiteralConstantSetIfNulls(node, constant, rhs, arg); 7416 return handleTypeLiteralConstantSetIfNulls(node, constant, rhs, arg);
11196 } 7417 }
11197 7418
11198 @override 7419 @override
11199 R visitDynamicPropertySetIfNull( 7420 R visitDynamicPropertySetIfNull(
11200 Send node, 7421 Send node, Node receiver, Name name, Node rhs, A arg) {
11201 Node receiver,
11202 Name name,
11203 Node rhs,
11204 A arg) {
11205 return handleDynamicSetIfNulls(node, receiver, name, rhs, arg); 7422 return handleDynamicSetIfNulls(node, receiver, name, rhs, arg);
11206 } 7423 }
11207 7424
11208 @override 7425 @override
11209 R visitDynamicTypeLiteralSetIfNull( 7426 R visitDynamicTypeLiteralSetIfNull(
11210 Send node, 7427 Send node, ConstantExpression constant, Node rhs, A arg) {
11211 ConstantExpression constant,
11212 Node rhs,
11213 A arg) {
11214 return handleTypeLiteralConstantSetIfNulls(node, constant, rhs, arg); 7428 return handleTypeLiteralConstantSetIfNulls(node, constant, rhs, arg);
11215 } 7429 }
11216 7430
11217 @override 7431 @override
11218 R visitFinalLocalVariableSetIfNull( 7432 R visitFinalLocalVariableSetIfNull(
11219 Send node, 7433 Send node, LocalVariableElement variable, Node rhs, A arg) {
11220 LocalVariableElement variable, 7434 return handleLocalSetIfNulls(node, variable, rhs, arg,
11221 Node rhs, 7435 isSetterValid: false);
11222 A arg) {
11223 return handleLocalSetIfNulls(
11224 node, variable, rhs, arg, isSetterValid: false);
11225 } 7436 }
11226 7437
11227 @override 7438 @override
11228 R visitFinalParameterSetIfNull( 7439 R visitFinalParameterSetIfNull(
11229 Send node, 7440 Send node, ParameterElement parameter, Node rhs, A arg) {
11230 ParameterElement parameter, 7441 return handleLocalSetIfNulls(node, parameter, rhs, arg,
11231 Node rhs, 7442 isSetterValid: false);
11232 A arg) {
11233 return handleLocalSetIfNulls(
11234 node, parameter, rhs, arg, isSetterValid: false);
11235 } 7443 }
11236 7444
11237 @override 7445 @override
11238 R visitFinalStaticFieldSetIfNull( 7446 R visitFinalStaticFieldSetIfNull(
11239 Send node, 7447 Send node, FieldElement field, Node rhs, A arg) {
11240 FieldElement field, 7448 return handleStaticSetIfNulls(node, field, CompoundGetter.FIELD, field,
11241 Node rhs, 7449 CompoundSetter.INVALID, rhs, arg);
11242 A arg) {
11243 return handleStaticSetIfNulls(
11244 node,
11245 field,
11246 CompoundGetter.FIELD,
11247 field,
11248 CompoundSetter.INVALID,
11249 rhs,
11250 arg);
11251 } 7450 }
11252 7451
11253 @override 7452 @override
11254 R visitFinalSuperFieldSetIfNull( 7453 R visitFinalSuperFieldSetIfNull(
11255 Send node, 7454 Send node, FieldElement field, Node rhs, A arg) {
11256 FieldElement field, 7455 return handleSuperSetIfNulls(node, field, CompoundGetter.FIELD, field,
11257 Node rhs, 7456 CompoundSetter.INVALID, rhs, arg);
11258 A arg) {
11259 return handleSuperSetIfNulls(
11260 node,
11261 field,
11262 CompoundGetter.FIELD,
11263 field,
11264 CompoundSetter.INVALID,
11265 rhs,
11266 arg);
11267 } 7457 }
11268 7458
11269 @override 7459 @override
11270 R visitFinalTopLevelFieldSetIfNull( 7460 R visitFinalTopLevelFieldSetIfNull(
11271 Send node, 7461 Send node, FieldElement field, Node rhs, A arg) {
11272 FieldElement field, 7462 return handleStaticSetIfNulls(node, field, CompoundGetter.FIELD, field,
11273 Node rhs, 7463 CompoundSetter.INVALID, rhs, arg);
11274 A arg) {
11275 return handleStaticSetIfNulls(
11276 node,
11277 field,
11278 CompoundGetter.FIELD,
11279 field,
11280 CompoundSetter.INVALID,
11281 rhs,
11282 arg);
11283 } 7464 }
11284 7465
11285 @override 7466 @override
11286 R visitIfNotNullDynamicPropertySetIfNull( 7467 R visitIfNotNullDynamicPropertySetIfNull(
11287 Send node, 7468 Send node, Node receiver, Name name, Node rhs, A arg) {
11288 Node receiver,
11289 Name name,
11290 Node rhs,
11291 A arg) {
11292 return handleDynamicSetIfNulls(node, receiver, name, rhs, arg); 7469 return handleDynamicSetIfNulls(node, receiver, name, rhs, arg);
11293 } 7470 }
11294 7471
11295 @override 7472 @override
11296 R visitLocalFunctionSetIfNull( 7473 R visitLocalFunctionSetIfNull(
11297 Send node, 7474 Send node, LocalFunctionElement function, Node rhs, A arg) {
11298 LocalFunctionElement function, 7475 return handleLocalSetIfNulls(node, function, rhs, arg,
11299 Node rhs, 7476 isSetterValid: false);
11300 A arg) {
11301 return handleLocalSetIfNulls(
11302 node, function, rhs, arg, isSetterValid: false);
11303 } 7477 }
11304 7478
11305 @override 7479 @override
11306 R visitLocalVariableSetIfNull( 7480 R visitLocalVariableSetIfNull(
11307 Send node, 7481 Send node, LocalVariableElement variable, Node rhs, A arg) {
11308 LocalVariableElement variable, 7482 return handleLocalSetIfNulls(node, variable, rhs, arg, isSetterValid: true);
11309 Node rhs,
11310 A arg) {
11311 return handleLocalSetIfNulls(
11312 node, variable, rhs, arg, isSetterValid: true);
11313 } 7483 }
11314 7484
11315 @override 7485 @override
11316 R visitParameterSetIfNull( 7486 R visitParameterSetIfNull(
11317 Send node, 7487 Send node, ParameterElement parameter, Node rhs, A arg) {
11318 ParameterElement parameter, 7488 return handleLocalSetIfNulls(node, parameter, rhs, arg,
11319 Node rhs, 7489 isSetterValid: true);
11320 A arg) { 7490 }
11321 return handleLocalSetIfNulls( 7491
11322 node, parameter, rhs, arg, isSetterValid: true); 7492 @override
11323 } 7493 R visitStaticFieldSetIfNull(Send node, FieldElement field, Node rhs, A arg) {
11324 7494 return handleStaticSetIfNulls(node, field, CompoundGetter.FIELD, field,
11325 @override 7495 CompoundSetter.FIELD, rhs, arg);
11326 R visitStaticFieldSetIfNull( 7496 }
11327 Send node, 7497
11328 FieldElement field, 7498 @override
11329 Node rhs, 7499 R visitStaticGetterSetterSetIfNull(Send node, FunctionElement getter,
11330 A arg) { 7500 FunctionElement setter, Node rhs, A arg) {
11331 return handleStaticSetIfNulls( 7501 return handleStaticSetIfNulls(node, getter, CompoundGetter.GETTER, setter,
11332 node, 7502 CompoundSetter.SETTER, rhs, arg);
11333 field,
11334 CompoundGetter.FIELD,
11335 field,
11336 CompoundSetter.FIELD,
11337 rhs,
11338 arg);
11339 }
11340
11341 @override
11342 R visitStaticGetterSetterSetIfNull(
11343 Send node,
11344 FunctionElement getter,
11345 FunctionElement setter,
11346 Node rhs,
11347 A arg) {
11348 return handleStaticSetIfNulls(
11349 node,
11350 getter,
11351 CompoundGetter.GETTER,
11352 setter,
11353 CompoundSetter.SETTER,
11354 rhs,
11355 arg);
11356 } 7503 }
11357 7504
11358 @override 7505 @override
11359 R visitStaticMethodSetIfNull( 7506 R visitStaticMethodSetIfNull(
11360 Send node, 7507 Send node, FunctionElement method, Node rhs, A arg) {
11361 FunctionElement method, 7508 return handleStaticSetIfNulls(node, method, CompoundGetter.METHOD, method,
11362 Node rhs, 7509 CompoundSetter.INVALID, rhs, arg);
11363 A arg) {
11364 return handleStaticSetIfNulls(
11365 node,
11366 method,
11367 CompoundGetter.METHOD,
11368 method,
11369 CompoundSetter.INVALID,
11370 rhs,
11371 arg);
11372 } 7510 }
11373 7511
11374 @override 7512 @override
11375 R visitStaticMethodSetterSetIfNull( 7513 R visitStaticMethodSetterSetIfNull(
11376 Send node, 7514 Send node, MethodElement method, MethodElement setter, Node rhs, A arg) {
11377 MethodElement method, 7515 return handleStaticSetIfNulls(node, method, CompoundGetter.METHOD, setter,
11378 MethodElement setter, 7516 CompoundSetter.SETTER, rhs, arg);
11379 Node rhs, 7517 }
11380 A arg) { 7518
11381 return handleStaticSetIfNulls( 7519 @override
11382 node, 7520 R visitSuperFieldFieldSetIfNull(Send node, FieldElement readField,
11383 method, 7521 FieldElement writtenField, Node rhs, A arg) {
11384 CompoundGetter.METHOD, 7522 return handleSuperSetIfNulls(node, readField, CompoundGetter.FIELD,
11385 setter, 7523 writtenField, CompoundSetter.FIELD, rhs, arg);
11386 CompoundSetter.SETTER, 7524 }
11387 rhs, 7525
11388 arg); 7526 @override
11389 } 7527 R visitSuperFieldSetIfNull(Send node, FieldElement field, Node rhs, A arg) {
11390 7528 return handleSuperSetIfNulls(node, field, CompoundGetter.FIELD, field,
11391 @override 7529 CompoundSetter.FIELD, rhs, arg);
11392 R visitSuperFieldFieldSetIfNull(
11393 Send node,
11394 FieldElement readField,
11395 FieldElement writtenField,
11396 Node rhs,
11397 A arg) {
11398 return handleSuperSetIfNulls(
11399 node,
11400 readField,
11401 CompoundGetter.FIELD,
11402 writtenField,
11403 CompoundSetter.FIELD,
11404 rhs,
11405 arg);
11406 }
11407
11408 @override
11409 R visitSuperFieldSetIfNull(
11410 Send node,
11411 FieldElement field,
11412 Node rhs,
11413 A arg) {
11414 return handleSuperSetIfNulls(
11415 node,
11416 field,
11417 CompoundGetter.FIELD,
11418 field,
11419 CompoundSetter.FIELD,
11420 rhs,
11421 arg);
11422 } 7530 }
11423 7531
11424 @override 7532 @override
11425 R visitSuperFieldSetterSetIfNull( 7533 R visitSuperFieldSetterSetIfNull(
11426 Send node, 7534 Send node, FieldElement field, FunctionElement setter, Node rhs, A arg) {
11427 FieldElement field, 7535 return handleSuperSetIfNulls(node, field, CompoundGetter.FIELD, setter,
11428 FunctionElement setter, 7536 CompoundSetter.SETTER, rhs, arg);
11429 Node rhs,
11430 A arg) {
11431 return handleSuperSetIfNulls(
11432 node,
11433 field,
11434 CompoundGetter.FIELD,
11435 setter,
11436 CompoundSetter.SETTER,
11437 rhs,
11438 arg);
11439 } 7537 }
11440 7538
11441 @override 7539 @override
11442 R visitSuperGetterFieldSetIfNull( 7540 R visitSuperGetterFieldSetIfNull(
11443 Send node, 7541 Send node, FunctionElement getter, FieldElement field, Node rhs, A arg) {
11444 FunctionElement getter, 7542 return handleSuperSetIfNulls(node, getter, CompoundGetter.GETTER, field,
11445 FieldElement field, 7543 CompoundSetter.FIELD, rhs, arg);
11446 Node rhs, 7544 }
11447 A arg) { 7545
11448 return handleSuperSetIfNulls( 7546 @override
11449 node, 7547 R visitSuperGetterSetterSetIfNull(Send node, FunctionElement getter,
11450 getter, 7548 FunctionElement setter, Node rhs, A arg) {
11451 CompoundGetter.GETTER, 7549 return handleSuperSetIfNulls(node, getter, CompoundGetter.GETTER, setter,
11452 field, 7550 CompoundSetter.SETTER, rhs, arg);
11453 CompoundSetter.FIELD,
11454 rhs,
11455 arg);
11456 }
11457
11458 @override
11459 R visitSuperGetterSetterSetIfNull(
11460 Send node,
11461 FunctionElement getter,
11462 FunctionElement setter,
11463 Node rhs,
11464 A arg) {
11465 return handleSuperSetIfNulls(
11466 node,
11467 getter,
11468 CompoundGetter.GETTER,
11469 setter,
11470 CompoundSetter.SETTER,
11471 rhs,
11472 arg);
11473 } 7551 }
11474 7552
11475 @override 7553 @override
11476 R visitSuperMethodSetIfNull( 7554 R visitSuperMethodSetIfNull(
11477 Send node, 7555 Send node, FunctionElement method, Node rhs, A arg) {
11478 FunctionElement method, 7556 return handleSuperSetIfNulls(node, method, CompoundGetter.METHOD, method,
11479 Node rhs, 7557 CompoundSetter.INVALID, rhs, arg);
11480 A arg) { 7558 }
11481 return handleSuperSetIfNulls( 7559
11482 node, 7560 @override
11483 method, 7561 R visitSuperMethodSetterSetIfNull(Send node, FunctionElement method,
11484 CompoundGetter.METHOD, 7562 FunctionElement setter, Node rhs, A arg) {
11485 method, 7563 return handleSuperSetIfNulls(node, method, CompoundGetter.METHOD, setter,
11486 CompoundSetter.INVALID, 7564 CompoundSetter.SETTER, rhs, arg);
11487 rhs, 7565 }
11488 arg); 7566
11489 } 7567 @override
11490 7568 R visitThisPropertySetIfNull(Send node, Name name, Node rhs, A arg) {
11491 @override
11492 R visitSuperMethodSetterSetIfNull(
11493 Send node,
11494 FunctionElement method,
11495 FunctionElement setter,
11496 Node rhs,
11497 A arg) {
11498 return handleSuperSetIfNulls(
11499 node,
11500 method,
11501 CompoundGetter.METHOD,
11502 setter,
11503 CompoundSetter.SETTER,
11504 rhs,
11505 arg);
11506 }
11507
11508 @override
11509 R visitThisPropertySetIfNull(
11510 Send node,
11511 Name name,
11512 Node rhs,
11513 A arg) {
11514 return handleDynamicSetIfNulls(node, null, name, rhs, arg); 7569 return handleDynamicSetIfNulls(node, null, name, rhs, arg);
11515 } 7570 }
11516 7571
11517 @override 7572 @override
11518 R visitTopLevelFieldSetIfNull( 7573 R visitTopLevelFieldSetIfNull(
11519 Send node, 7574 Send node, FieldElement field, Node rhs, A arg) {
11520 FieldElement field, 7575 return handleStaticSetIfNulls(node, field, CompoundGetter.FIELD, field,
11521 Node rhs, 7576 CompoundSetter.FIELD, rhs, arg);
11522 A arg) { 7577 }
11523 return handleStaticSetIfNulls( 7578
11524 node, 7579 @override
11525 field, 7580 R visitTopLevelGetterSetterSetIfNull(Send node, FunctionElement getter,
11526 CompoundGetter.FIELD, 7581 FunctionElement setter, Node rhs, A arg) {
11527 field, 7582 return handleStaticSetIfNulls(node, getter, CompoundGetter.GETTER, setter,
11528 CompoundSetter.FIELD, 7583 CompoundSetter.SETTER, rhs, arg);
11529 rhs,
11530 arg);
11531 }
11532
11533 @override
11534 R visitTopLevelGetterSetterSetIfNull(
11535 Send node,
11536 FunctionElement getter,
11537 FunctionElement setter,
11538 Node rhs,
11539 A arg) {
11540 return handleStaticSetIfNulls(
11541 node,
11542 getter,
11543 CompoundGetter.GETTER,
11544 setter,
11545 CompoundSetter.SETTER,
11546 rhs,
11547 arg);
11548 } 7584 }
11549 7585
11550 @override 7586 @override
11551 R visitTopLevelMethodSetIfNull( 7587 R visitTopLevelMethodSetIfNull(
11552 Send node, 7588 Send node, FunctionElement method, Node rhs, A arg) {
11553 FunctionElement method, 7589 return handleStaticSetIfNulls(node, method, CompoundGetter.METHOD, method,
11554 Node rhs, 7590 CompoundSetter.INVALID, rhs, arg);
11555 A arg) { 7591 }
11556 return handleStaticSetIfNulls( 7592
11557 node, 7593 @override
11558 method, 7594 R visitTopLevelMethodSetterSetIfNull(Send node, FunctionElement method,
11559 CompoundGetter.METHOD, 7595 FunctionElement setter, Node rhs, A arg) {
11560 method, 7596 return handleStaticSetIfNulls(node, method, CompoundGetter.METHOD, setter,
11561 CompoundSetter.INVALID, 7597 CompoundSetter.SETTER, rhs, arg);
11562 rhs,
11563 arg);
11564 }
11565
11566 @override
11567 R visitTopLevelMethodSetterSetIfNull(
11568 Send node,
11569 FunctionElement method,
11570 FunctionElement setter,
11571 Node rhs,
11572 A arg) {
11573 return handleStaticSetIfNulls(
11574 node,
11575 method,
11576 CompoundGetter.METHOD,
11577 setter,
11578 CompoundSetter.SETTER,
11579 rhs,
11580 arg);
11581 } 7598 }
11582 7599
11583 @override 7600 @override
11584 R visitTypedefTypeLiteralSetIfNull( 7601 R visitTypedefTypeLiteralSetIfNull(
11585 Send node, 7602 Send node, ConstantExpression constant, Node rhs, A arg) {
11586 ConstantExpression constant,
11587 Node rhs,
11588 A arg) {
11589 return handleTypeLiteralConstantSetIfNulls(node, constant, rhs, arg); 7603 return handleTypeLiteralConstantSetIfNulls(node, constant, rhs, arg);
11590 } 7604 }
11591 7605
11592 @override 7606 @override
11593 R visitUnresolvedSetIfNull( 7607 R visitUnresolvedSetIfNull(Send node, Element element, Node rhs, A arg) {
11594 Send node, 7608 return handleStaticSetIfNulls(node, element, CompoundGetter.UNRESOLVED,
11595 Element element, 7609 element, CompoundSetter.INVALID, rhs, arg);
11596 Node rhs,
11597 A arg) {
11598 return handleStaticSetIfNulls(
11599 node,
11600 element,
11601 CompoundGetter.UNRESOLVED,
11602 element,
11603 CompoundSetter.INVALID,
11604 rhs,
11605 arg);
11606 } 7610 }
11607 7611
11608 @override 7612 @override
11609 R visitUnresolvedStaticGetterSetIfNull( 7613 R visitUnresolvedStaticGetterSetIfNull(
11610 Send node, 7614 Send node, Element element, MethodElement setter, Node rhs, A arg) {
11611 Element element, 7615 return handleStaticSetIfNulls(node, element, CompoundGetter.UNRESOLVED,
11612 MethodElement setter, 7616 setter, CompoundSetter.SETTER, rhs, arg);
11613 Node rhs,
11614 A arg) {
11615 return handleStaticSetIfNulls(
11616 node,
11617 element,
11618 CompoundGetter.UNRESOLVED,
11619 setter,
11620 CompoundSetter.SETTER,
11621 rhs,
11622 arg);
11623 } 7617 }
11624 7618
11625 @override 7619 @override
11626 R visitUnresolvedStaticSetterSetIfNull( 7620 R visitUnresolvedStaticSetterSetIfNull(
11627 Send node, 7621 Send node, MethodElement getter, Element element, Node rhs, A arg) {
11628 MethodElement getter, 7622 return handleStaticSetIfNulls(node, getter, CompoundGetter.GETTER, element,
11629 Element element, 7623 CompoundSetter.INVALID, rhs, arg);
11630 Node rhs,
11631 A arg) {
11632 return handleStaticSetIfNulls(
11633 node,
11634 getter,
11635 CompoundGetter.GETTER,
11636 element,
11637 CompoundSetter.INVALID,
11638 rhs,
11639 arg);
11640 } 7624 }
11641 7625
11642 @override 7626 @override
11643 R visitUnresolvedSuperGetterSetIfNull( 7627 R visitUnresolvedSuperGetterSetIfNull(
11644 Send node, 7628 Send node, Element element, MethodElement setter, Node rhs, A arg) {
11645 Element element, 7629 return handleSuperSetIfNulls(node, element, CompoundGetter.UNRESOLVED,
11646 MethodElement setter, 7630 setter, CompoundSetter.SETTER, rhs, arg);
11647 Node rhs, 7631 }
11648 A arg) { 7632
11649 return handleSuperSetIfNulls( 7633 @override
11650 node, 7634 R visitUnresolvedSuperSetIfNull(Send node, Element element, Node rhs, A arg) {
11651 element, 7635 return handleSuperSetIfNulls(node, element, CompoundGetter.UNRESOLVED,
11652 CompoundGetter.UNRESOLVED, 7636 element, CompoundSetter.INVALID, rhs, arg);
11653 setter,
11654 CompoundSetter.SETTER,
11655 rhs,
11656 arg);
11657 }
11658
11659 @override
11660 R visitUnresolvedSuperSetIfNull(
11661 Send node,
11662 Element element,
11663 Node rhs,
11664 A arg) {
11665 return handleSuperSetIfNulls(
11666 node,
11667 element,
11668 CompoundGetter.UNRESOLVED,
11669 element,
11670 CompoundSetter.INVALID,
11671 rhs,
11672 arg);
11673 } 7637 }
11674 7638
11675 @override 7639 @override
11676 R visitUnresolvedSuperSetterSetIfNull( 7640 R visitUnresolvedSuperSetterSetIfNull(
11677 Send node, 7641 Send node, MethodElement getter, Element element, Node rhs, A arg) {
11678 MethodElement getter, 7642 return handleSuperSetIfNulls(node, getter, CompoundGetter.GETTER, element,
11679 Element element, 7643 CompoundSetter.INVALID, rhs, arg);
11680 Node rhs,
11681 A arg) {
11682 return handleSuperSetIfNulls(
11683 node,
11684 getter,
11685 CompoundGetter.GETTER,
11686 element,
11687 CompoundSetter.INVALID,
11688 rhs,
11689 arg);
11690 } 7644 }
11691 7645
11692 @override 7646 @override
11693 R visitUnresolvedTopLevelGetterSetIfNull( 7647 R visitUnresolvedTopLevelGetterSetIfNull(
11694 Send node, 7648 Send node, Element element, MethodElement setter, Node rhs, A arg) {
11695 Element element, 7649 return handleStaticSetIfNulls(node, element, CompoundGetter.UNRESOLVED,
11696 MethodElement setter, 7650 setter, CompoundSetter.SETTER, rhs, arg);
11697 Node rhs,
11698 A arg) {
11699 return handleStaticSetIfNulls(
11700 node,
11701 element,
11702 CompoundGetter.UNRESOLVED,
11703 setter,
11704 CompoundSetter.SETTER,
11705 rhs,
11706 arg);
11707 } 7651 }
11708 7652
11709 @override 7653 @override
11710 R visitUnresolvedTopLevelSetterSetIfNull( 7654 R visitUnresolvedTopLevelSetterSetIfNull(
11711 Send node, 7655 Send node, MethodElement getter, Element element, Node rhs, A arg) {
11712 MethodElement getter, 7656 return handleStaticSetIfNulls(node, getter, CompoundGetter.GETTER, element,
11713 Element element, 7657 CompoundSetter.INVALID, rhs, arg);
11714 Node rhs,
11715 A arg) {
11716 return handleStaticSetIfNulls(
11717 node,
11718 getter,
11719 CompoundGetter.GETTER,
11720 element,
11721 CompoundSetter.INVALID,
11722 rhs,
11723 arg);
11724 } 7658 }
11725 } 7659 }
11726 7660
11727 /// Simplified handling of indexed compound assignments and prefix/postfix 7661 /// Simplified handling of indexed compound assignments and prefix/postfix
11728 /// expressions. 7662 /// expressions.
11729 abstract class BaseImplementationOfIndexCompoundsMixin<R, A> 7663 abstract class BaseImplementationOfIndexCompoundsMixin<R, A>
11730 implements SemanticSendVisitor<R, A> { 7664 implements SemanticSendVisitor<R, A> {
11731
11732 /// Handle a dynamic index compounds, like `receiver[index] += rhs` or 7665 /// Handle a dynamic index compounds, like `receiver[index] += rhs` or
11733 /// `--receiver[index]`. 7666 /// `--receiver[index]`.
11734 R handleIndexCompounds( 7667 R handleIndexCompounds(
11735 SendSet node, 7668 SendSet node, Node receiver, Node index, CompoundRhs rhs, A arg);
11736 Node receiver,
11737 Node index,
11738 CompoundRhs rhs,
11739 A arg);
11740 7669
11741 /// Handle a super index compounds, like `super[index] += rhs` or 7670 /// Handle a super index compounds, like `super[index] += rhs` or
11742 /// `--super[index]`. 7671 /// `--super[index]`.
11743 R handleSuperIndexCompounds( 7672 R handleSuperIndexCompounds(SendSet node, Element indexFunction,
11744 SendSet node, 7673 Element indexSetFunction, Node index, CompoundRhs rhs, A arg,
11745 Element indexFunction, 7674 {bool isGetterValid, bool isSetterValid});
11746 Element indexSetFunction,
11747 Node index,
11748 CompoundRhs rhs,
11749 A arg,
11750 {bool isGetterValid,
11751 bool isSetterValid});
11752 7675
11753 @override 7676 @override
11754 R visitSuperCompoundIndexSet( 7677 R visitSuperCompoundIndexSet(
11755 Send node, 7678 Send node,
11756 FunctionElement indexFunction, 7679 FunctionElement indexFunction,
11757 FunctionElement indexSetFunction, 7680 FunctionElement indexSetFunction,
11758 Node index, 7681 Node index,
11759 AssignmentOperator operator, 7682 AssignmentOperator operator,
11760 Node rhs, 7683 Node rhs,
11761 A arg) { 7684 A arg) {
11762 return handleSuperIndexCompounds( 7685 return handleSuperIndexCompounds(node, indexFunction, indexSetFunction,
11763 node, indexFunction, indexSetFunction, index, 7686 index, new AssignmentCompound(operator, rhs), arg,
11764 new AssignmentCompound(operator, rhs), arg,
11765 isGetterValid: true, isSetterValid: true); 7687 isGetterValid: true, isSetterValid: true);
11766 } 7688 }
11767 7689
11768 @override 7690 @override
11769 R visitSuperIndexPostfix( 7691 R visitSuperIndexPostfix(
11770 Send node, 7692 Send node,
11771 FunctionElement indexFunction, 7693 FunctionElement indexFunction,
11772 FunctionElement indexSetFunction, 7694 FunctionElement indexSetFunction,
11773 Node index, 7695 Node index,
11774 IncDecOperator operator, 7696 IncDecOperator operator,
11775 A arg) { 7697 A arg) {
11776 return handleSuperIndexCompounds( 7698 return handleSuperIndexCompounds(node, indexFunction, indexSetFunction,
11777 node, indexFunction, indexSetFunction, index, 7699 index, new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
11778 new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
11779 isGetterValid: true, isSetterValid: true); 7700 isGetterValid: true, isSetterValid: true);
11780 } 7701 }
11781 7702
11782 @override 7703 @override
11783 R visitSuperIndexPrefix( 7704 R visitSuperIndexPrefix(
11784 Send node, 7705 Send node,
11785 FunctionElement indexFunction, 7706 FunctionElement indexFunction,
11786 FunctionElement indexSetFunction, 7707 FunctionElement indexSetFunction,
11787 Node index, 7708 Node index,
11788 IncDecOperator operator, 7709 IncDecOperator operator,
11789 A arg) { 7710 A arg) {
11790 return handleSuperIndexCompounds( 7711 return handleSuperIndexCompounds(node, indexFunction, indexSetFunction,
11791 node, indexFunction, indexSetFunction, index, 7712 index, new IncDecCompound(CompoundKind.PREFIX, operator), arg,
11792 new IncDecCompound(CompoundKind.PREFIX, operator), arg,
11793 isGetterValid: true, isSetterValid: true); 7713 isGetterValid: true, isSetterValid: true);
11794 } 7714 }
11795 7715
11796 @override 7716 @override
11797 R visitUnresolvedSuperGetterCompoundIndexSet( 7717 R visitUnresolvedSuperGetterCompoundIndexSet(
11798 Send node, 7718 Send node,
11799 Element indexFunction, 7719 Element indexFunction,
11800 FunctionElement indexSetFunction, 7720 FunctionElement indexSetFunction,
11801 Node index, 7721 Node index,
11802 AssignmentOperator operator, 7722 AssignmentOperator operator,
11803 Node rhs, 7723 Node rhs,
11804 A arg) { 7724 A arg) {
11805 return handleSuperIndexCompounds( 7725 return handleSuperIndexCompounds(node, indexFunction, indexSetFunction,
11806 node, indexFunction, indexSetFunction, index, 7726 index, new AssignmentCompound(operator, rhs), arg,
11807 new AssignmentCompound(operator, rhs), arg,
11808 isGetterValid: false, isSetterValid: true); 7727 isGetterValid: false, isSetterValid: true);
11809 } 7728 }
11810 7729
11811 @override 7730 @override
11812 R visitUnresolvedSuperSetterCompoundIndexSet( 7731 R visitUnresolvedSuperSetterCompoundIndexSet(
11813 Send node, 7732 Send node,
11814 FunctionElement indexFunction, 7733 FunctionElement indexFunction,
11815 Element indexSetFunction, 7734 Element indexSetFunction,
11816 Node index, 7735 Node index,
11817 AssignmentOperator operator, 7736 AssignmentOperator operator,
11818 Node rhs, 7737 Node rhs,
11819 A arg) { 7738 A arg) {
11820 return handleSuperIndexCompounds( 7739 return handleSuperIndexCompounds(node, indexFunction, indexSetFunction,
11821 node, indexFunction, indexSetFunction, index, 7740 index, new AssignmentCompound(operator, rhs), arg,
11822 new AssignmentCompound(operator, rhs), arg,
11823 isGetterValid: true, isSetterValid: false); 7741 isGetterValid: true, isSetterValid: false);
11824 } 7742 }
11825 7743
11826 @override 7744 @override
11827 R visitUnresolvedSuperCompoundIndexSet( 7745 R visitUnresolvedSuperCompoundIndexSet(Send node, Element element, Node index,
11828 Send node, 7746 AssignmentOperator operator, Node rhs, A arg) {
11829 Element element, 7747 return handleSuperIndexCompounds(node, element, element, index,
11830 Node index,
11831 AssignmentOperator operator,
11832 Node rhs,
11833 A arg) {
11834 return handleSuperIndexCompounds(
11835 node, element, element, index,
11836 new AssignmentCompound(operator, rhs), arg, 7748 new AssignmentCompound(operator, rhs), arg,
11837 isGetterValid: false, isSetterValid: false); 7749 isGetterValid: false, isSetterValid: false);
11838 } 7750 }
11839 7751
11840 @override 7752 @override
11841 R visitUnresolvedSuperGetterIndexPostfix( 7753 R visitUnresolvedSuperGetterIndexPostfix(
11842 Send node, 7754 Send node,
11843 Element element, 7755 Element element,
11844 FunctionElement indexSetFunction, 7756 FunctionElement indexSetFunction,
11845 Node index, 7757 Node index,
11846 IncDecOperator operator, 7758 IncDecOperator operator,
11847 A arg) { 7759 A arg) {
11848 return handleSuperIndexCompounds( 7760 return handleSuperIndexCompounds(node, element, indexSetFunction, index,
11849 node, element, indexSetFunction, index,
11850 new IncDecCompound(CompoundKind.POSTFIX, operator), arg, 7761 new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
11851 isGetterValid: false, isSetterValid: true); 7762 isGetterValid: false, isSetterValid: true);
11852 } 7763 }
11853 7764
11854 @override 7765 @override
11855 R visitUnresolvedSuperGetterIndexPrefix( 7766 R visitUnresolvedSuperGetterIndexPrefix(
11856 Send node, 7767 Send node,
11857 Element element, 7768 Element element,
11858 FunctionElement indexSetFunction, 7769 FunctionElement indexSetFunction,
11859 Node index, 7770 Node index,
11860 IncDecOperator operator, 7771 IncDecOperator operator,
11861 A arg) { 7772 A arg) {
11862 return handleSuperIndexCompounds( 7773 return handleSuperIndexCompounds(node, element, indexSetFunction, index,
11863 node, element, indexSetFunction, index,
11864 new IncDecCompound(CompoundKind.PREFIX, operator), arg, 7774 new IncDecCompound(CompoundKind.PREFIX, operator), arg,
11865 isGetterValid: false, isSetterValid: true); 7775 isGetterValid: false, isSetterValid: true);
11866 } 7776 }
11867 7777
11868 @override 7778 @override
11869 R visitUnresolvedSuperSetterIndexPostfix( 7779 R visitUnresolvedSuperSetterIndexPostfix(
11870 Send node, 7780 Send node,
11871 MethodElement indexFunction, 7781 MethodElement indexFunction,
11872 Element element, 7782 Element element,
11873 Node index, 7783 Node index,
11874 IncDecOperator operator, 7784 IncDecOperator operator,
11875 A arg) { 7785 A arg) {
11876 return handleSuperIndexCompounds( 7786 return handleSuperIndexCompounds(node, indexFunction, element, index,
11877 node, indexFunction, element, index,
11878 new IncDecCompound(CompoundKind.POSTFIX, operator), arg, 7787 new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
11879 isGetterValid: true, isSetterValid: false); 7788 isGetterValid: true, isSetterValid: false);
11880 } 7789 }
11881 7790
11882 @override 7791 @override
11883 R visitUnresolvedSuperSetterIndexPrefix( 7792 R visitUnresolvedSuperSetterIndexPrefix(
11884 Send node, 7793 Send node,
11885 MethodElement indexFunction, 7794 MethodElement indexFunction,
11886 Element element, 7795 Element element,
11887 Node index, 7796 Node index,
11888 IncDecOperator operator, 7797 IncDecOperator operator,
11889 A arg) { 7798 A arg) {
11890 return handleSuperIndexCompounds( 7799 return handleSuperIndexCompounds(node, indexFunction, element, index,
11891 node, indexFunction, element, index,
11892 new IncDecCompound(CompoundKind.PREFIX, operator), arg, 7800 new IncDecCompound(CompoundKind.PREFIX, operator), arg,
11893 isGetterValid: true, isSetterValid: false); 7801 isGetterValid: true, isSetterValid: false);
11894 } 7802 }
11895 7803
11896 @override 7804 @override
11897 R visitUnresolvedSuperIndexPostfix( 7805 R visitUnresolvedSuperIndexPostfix(
11898 Send node, 7806 Send node, Element element, Node index, IncDecOperator operator, A arg) {
11899 Element element, 7807 return handleSuperIndexCompounds(node, element, element, index,
11900 Node index,
11901 IncDecOperator operator,
11902 A arg) {
11903 return handleSuperIndexCompounds(
11904 node, element, element, index,
11905 new IncDecCompound(CompoundKind.POSTFIX, operator), arg, 7808 new IncDecCompound(CompoundKind.POSTFIX, operator), arg,
11906 isGetterValid: false, isSetterValid: false); 7809 isGetterValid: false, isSetterValid: false);
11907 } 7810 }
11908 7811
11909 @override 7812 @override
11910 R visitUnresolvedSuperIndexPrefix( 7813 R visitUnresolvedSuperIndexPrefix(
11911 Send node, 7814 Send node, Element element, Node index, IncDecOperator operator, A arg) {
11912 Element element, 7815 return handleSuperIndexCompounds(node, element, element, index,
11913 Node index,
11914 IncDecOperator operator,
11915 A arg) {
11916 return handleSuperIndexCompounds(
11917 node, element, element, index,
11918 new IncDecCompound(CompoundKind.PREFIX, operator), arg, 7816 new IncDecCompound(CompoundKind.PREFIX, operator), arg,
11919 isGetterValid: false, isSetterValid: false); 7817 isGetterValid: false, isSetterValid: false);
11920 } 7818 }
11921 7819
11922 @override 7820 @override
11923 R visitCompoundIndexSet( 7821 R visitCompoundIndexSet(SendSet node, Node receiver, Node index,
11924 SendSet node, 7822 AssignmentOperator operator, Node rhs, A arg) {
11925 Node receiver,
11926 Node index,
11927 AssignmentOperator operator,
11928 Node rhs,
11929 A arg) {
11930 return handleIndexCompounds( 7823 return handleIndexCompounds(
11931 node, receiver, index, 7824 node, receiver, index, new AssignmentCompound(operator, rhs), arg);
11932 new AssignmentCompound(operator, rhs), arg);
11933 } 7825 }
11934 7826
11935 @override 7827 @override
11936 R visitIndexPostfix( 7828 R visitIndexPostfix(
11937 Send node, 7829 Send node, Node receiver, Node index, IncDecOperator operator, A arg) {
11938 Node receiver, 7830 return handleIndexCompounds(node, receiver, index,
11939 Node index,
11940 IncDecOperator operator,
11941 A arg) {
11942 return handleIndexCompounds(
11943 node, receiver, index,
11944 new IncDecCompound(CompoundKind.POSTFIX, operator), arg); 7831 new IncDecCompound(CompoundKind.POSTFIX, operator), arg);
11945 } 7832 }
11946 7833
11947 @override 7834 @override
11948 R visitIndexPrefix( 7835 R visitIndexPrefix(
11949 Send node, 7836 Send node, Node receiver, Node index, IncDecOperator operator, A arg) {
11950 Node receiver, 7837 return handleIndexCompounds(node, receiver, index,
11951 Node index,
11952 IncDecOperator operator,
11953 A arg) {
11954 return handleIndexCompounds(
11955 node, receiver, index,
11956 new IncDecCompound(CompoundKind.PREFIX, operator), arg); 7838 new IncDecCompound(CompoundKind.PREFIX, operator), arg);
11957 } 7839 }
11958 } 7840 }
11959 7841
11960 /// Simplified handling of super if-null assignments. 7842 /// Simplified handling of super if-null assignments.
11961 abstract class BaseImplementationOfSuperIndexSetIfNullMixin<R, A> 7843 abstract class BaseImplementationOfSuperIndexSetIfNullMixin<R, A>
11962 implements SemanticSendVisitor<R, A> { 7844 implements SemanticSendVisitor<R, A> {
11963
11964 /// Handle a super index if-null assignments, like `super[index] ??= rhs`. 7845 /// Handle a super index if-null assignments, like `super[index] ??= rhs`.
11965 R handleSuperIndexSetIfNull( 7846 R handleSuperIndexSetIfNull(SendSet node, Element indexFunction,
11966 SendSet node, 7847 Element indexSetFunction, Node index, Node rhs, A arg,
11967 Element indexFunction, 7848 {bool isGetterValid, bool isSetterValid});
11968 Element indexSetFunction,
11969 Node index,
11970 Node rhs,
11971 A arg,
11972 {bool isGetterValid,
11973 bool isSetterValid});
11974 7849
11975 @override 7850 @override
11976 R visitSuperIndexSetIfNull( 7851 R visitSuperIndexSetIfNull(Send node, FunctionElement indexFunction,
11977 Send node, 7852 FunctionElement indexSetFunction, Node index, Node rhs, A arg) {
11978 FunctionElement indexFunction,
11979 FunctionElement indexSetFunction,
11980 Node index,
11981 Node rhs,
11982 A arg) {
11983 return handleSuperIndexSetIfNull( 7853 return handleSuperIndexSetIfNull(
11984 node, indexFunction, indexSetFunction, index, rhs, arg, 7854 node, indexFunction, indexSetFunction, index, rhs, arg,
11985 isGetterValid: true, isSetterValid: true); 7855 isGetterValid: true, isSetterValid: true);
11986 } 7856 }
11987 7857
11988 @override 7858 @override
11989 R visitUnresolvedSuperGetterIndexSetIfNull( 7859 R visitUnresolvedSuperGetterIndexSetIfNull(Send node, Element indexFunction,
11990 Send node, 7860 FunctionElement indexSetFunction, Node index, Node rhs, A arg) {
11991 Element indexFunction,
11992 FunctionElement indexSetFunction,
11993 Node index,
11994 Node rhs,
11995 A arg) {
11996 return handleSuperIndexSetIfNull( 7861 return handleSuperIndexSetIfNull(
11997 node, indexFunction, indexSetFunction, index, rhs, arg, 7862 node, indexFunction, indexSetFunction, index, rhs, arg,
11998 isGetterValid: false, isSetterValid: true); 7863 isGetterValid: false, isSetterValid: true);
11999 } 7864 }
12000 7865
12001 @override 7866 @override
12002 R visitUnresolvedSuperSetterIndexSetIfNull( 7867 R visitUnresolvedSuperSetterIndexSetIfNull(
12003 Send node, 7868 Send node,
12004 FunctionElement indexFunction, 7869 FunctionElement indexFunction,
12005 Element indexSetFunction, 7870 Element indexSetFunction,
12006 Node index, 7871 Node index,
12007 Node rhs, 7872 Node rhs,
12008 A arg) { 7873 A arg) {
12009 return handleSuperIndexSetIfNull( 7874 return handleSuperIndexSetIfNull(
12010 node, indexFunction, indexSetFunction, index, rhs, arg, 7875 node, indexFunction, indexSetFunction, index, rhs, arg,
12011 isGetterValid: true, isSetterValid: false); 7876 isGetterValid: true, isSetterValid: false);
12012 } 7877 }
12013 7878
12014 @override 7879 @override
12015 R visitUnresolvedSuperIndexSetIfNull( 7880 R visitUnresolvedSuperIndexSetIfNull(
12016 Send node, 7881 Send node, Element element, Node index, Node rhs, A arg) {
12017 Element element, 7882 return handleSuperIndexSetIfNull(node, element, element, index, rhs, arg,
12018 Node index,
12019 Node rhs,
12020 A arg) {
12021 return handleSuperIndexSetIfNull(
12022 node, element, element, index, rhs, arg,
12023 isGetterValid: false, isSetterValid: false); 7883 isGetterValid: false, isSetterValid: false);
12024 } 7884 }
12025 } 7885 }
12026 7886
12027 /// Mixin that groups all `visitSuperXPrefix`, `visitSuperXPostfix` methods by 7887 /// Mixin that groups all `visitSuperXPrefix`, `visitSuperXPostfix` methods by
12028 /// delegating calls to `handleSuperXPostfixPrefix` methods. 7888 /// delegating calls to `handleSuperXPostfixPrefix` methods.
12029 /// 7889 ///
12030 /// This mixin is useful for the cases where super prefix/postfix expression are 7890 /// This mixin is useful for the cases where super prefix/postfix expression are
12031 /// handled uniformly. 7891 /// handled uniformly.
12032 abstract class BaseImplementationOfSuperIncDecsMixin<R, A> 7892 abstract class BaseImplementationOfSuperIncDecsMixin<R, A>
12033 implements SemanticSendVisitor<R, A> { 7893 implements SemanticSendVisitor<R, A> {
12034 R handleSuperFieldFieldPostfixPrefix( 7894 R handleSuperFieldFieldPostfixPrefix(Send node, FieldElement readField,
12035 Send node, 7895 FieldElement writtenField, IncDecOperator operator, A arg,
12036 FieldElement readField,
12037 FieldElement writtenField,
12038 IncDecOperator operator,
12039 A arg,
12040 {bool isPrefix}); 7896 {bool isPrefix});
12041 7897
12042 R handleSuperFieldSetterPostfixPrefix( 7898 R handleSuperFieldSetterPostfixPrefix(Send node, FieldElement field,
12043 Send node, 7899 FunctionElement setter, IncDecOperator operator, A arg,
12044 FieldElement field,
12045 FunctionElement setter,
12046 IncDecOperator operator,
12047 A arg,
12048 {bool isPrefix}); 7900 {bool isPrefix});
12049 7901
12050 R handleSuperGetterFieldPostfixPrefix( 7902 R handleSuperGetterFieldPostfixPrefix(Send node, FunctionElement getter,
12051 Send node, 7903 FieldElement field, IncDecOperator operator, A arg,
12052 FunctionElement getter,
12053 FieldElement field,
12054 IncDecOperator operator,
12055 A arg,
12056 {bool isPrefix}); 7904 {bool isPrefix});
12057 7905
12058 R handleSuperGetterSetterPostfixPrefix( 7906 R handleSuperGetterSetterPostfixPrefix(Send node, FunctionElement getter,
12059 Send node, 7907 FunctionElement setter, IncDecOperator operator, A arg,
12060 FunctionElement getter,
12061 FunctionElement setter,
12062 IncDecOperator operator,
12063 A arg,
12064 {bool isPrefix}); 7908 {bool isPrefix});
12065 7909
12066 R handleSuperMethodSetterPostfixPrefix( 7910 R handleSuperMethodSetterPostfixPrefix(Send node, FunctionElement method,
12067 Send node, 7911 FunctionElement setter, IncDecOperator operator, A arg,
12068 FunctionElement method,
12069 FunctionElement setter,
12070 IncDecOperator operator,
12071 A arg,
12072 {bool isPrefix}); 7912 {bool isPrefix});
12073 7913
12074 R handleSuperIndexPostfixPrefix( 7914 R handleSuperIndexPostfixPrefix(
12075 Send node, 7915 Send node,
12076 FunctionElement indexFunction, 7916 FunctionElement indexFunction,
12077 FunctionElement indexSetFunction, 7917 FunctionElement indexSetFunction,
12078 Node index, 7918 Node index,
12079 IncDecOperator operator, 7919 IncDecOperator operator,
12080 A arg, 7920 A arg,
12081 {bool isPrefix}); 7921 {bool isPrefix});
12082 7922
12083 R handleUnresolvedSuperGetterIndexPostfixPrefix( 7923 R handleUnresolvedSuperGetterIndexPostfixPrefix(Send node, Element element,
12084 Send node, 7924 MethodElement setter, Node index, IncDecOperator operator, A arg,
12085 Element element,
12086 MethodElement setter,
12087 Node index,
12088 IncDecOperator operator,
12089 A arg,
12090 {bool isPrefix}); 7925 {bool isPrefix});
12091 7926
12092 R handleUnresolvedSuperSetterIndexPostfixPrefix( 7927 R handleUnresolvedSuperSetterIndexPostfixPrefix(
12093 Send node, 7928 Send node,
12094 FunctionElement indexFunction, 7929 FunctionElement indexFunction,
12095 Element element, 7930 Element element,
12096 Node index, 7931 Node index,
12097 IncDecOperator operator, 7932 IncDecOperator operator,
12098 A arg, 7933 A arg,
12099 {bool isPrefix}); 7934 {bool isPrefix});
12100 7935
12101 R handleUnresolvedSuperIndexPostfixPrefix( 7936 R handleUnresolvedSuperIndexPostfixPrefix(
12102 Send node, 7937 Send node, Element element, Node index, IncDecOperator operator, A arg,
12103 Element element,
12104 Node index,
12105 IncDecOperator operator,
12106 A arg,
12107 {bool isPrefix}); 7938 {bool isPrefix});
12108 7939
12109 R handleFinalSuperFieldPostfixPrefix( 7940 R handleFinalSuperFieldPostfixPrefix(
12110 Send node, 7941 Send node, FieldElement field, IncDecOperator operator, A arg,
12111 FieldElement field,
12112 IncDecOperator operator,
12113 A arg,
12114 {bool isPrefix}); 7942 {bool isPrefix});
12115 7943
12116 R handleSuperMethodPostfixPrefix( 7944 R handleSuperMethodPostfixPrefix(
12117 Send node, 7945 Send node, MethodElement method, IncDecOperator operator, A arg,
12118 MethodElement method,
12119 IncDecOperator operator,
12120 A arg,
12121 {bool isPrefix}); 7946 {bool isPrefix});
12122 7947
12123 R handleUnresolvedSuperPostfixPrefix( 7948 R handleUnresolvedSuperPostfixPrefix(
12124 Send node, 7949 Send node, Element element, IncDecOperator operator, A arg,
12125 Element element,
12126 IncDecOperator operator,
12127 A arg,
12128 {bool isPrefix}); 7950 {bool isPrefix});
12129 7951
12130 R handleUnresolvedSuperGetterPostfixPrefix( 7952 R handleUnresolvedSuperGetterPostfixPrefix(Send node, Element element,
12131 Send node, 7953 MethodElement setter, IncDecOperator operator, A arg,
12132 Element element,
12133 MethodElement setter,
12134 IncDecOperator operator,
12135 A arg,
12136 {bool isPrefix}); 7954 {bool isPrefix});
12137 7955
12138 R handleUnresolvedSuperSetterPostfixPrefix( 7956 R handleUnresolvedSuperSetterPostfixPrefix(Send node, MethodElement getter,
12139 Send node, 7957 Element element, IncDecOperator operator, A arg,
12140 MethodElement getter,
12141 Element element,
12142 IncDecOperator operator,
12143 A arg,
12144 {bool isPrefix}); 7958 {bool isPrefix});
12145 7959
12146 @override 7960 @override
12147 R visitSuperFieldFieldPostfix( 7961 R visitSuperFieldFieldPostfix(Send node, FieldElement readField,
12148 Send node, 7962 FieldElement writtenField, IncDecOperator operator, A arg) {
12149 FieldElement readField,
12150 FieldElement writtenField,
12151 IncDecOperator operator,
12152 A arg) {
12153 return handleSuperFieldFieldPostfixPrefix( 7963 return handleSuperFieldFieldPostfixPrefix(
12154 node, readField, writtenField, operator, arg, isPrefix: false); 7964 node, readField, writtenField, operator, arg,
7965 isPrefix: false);
12155 } 7966 }
12156 7967
12157 @override 7968 @override
12158 R visitSuperFieldFieldPrefix( 7969 R visitSuperFieldFieldPrefix(Send node, FieldElement readField,
12159 Send node, 7970 FieldElement writtenField, IncDecOperator operator, A arg) {
12160 FieldElement readField,
12161 FieldElement writtenField,
12162 IncDecOperator operator,
12163 A arg) {
12164 return handleSuperFieldFieldPostfixPrefix( 7971 return handleSuperFieldFieldPostfixPrefix(
12165 node, readField, writtenField, operator, arg, isPrefix: true); 7972 node, readField, writtenField, operator, arg,
7973 isPrefix: true);
12166 } 7974 }
12167 7975
12168 @override 7976 @override
12169 R visitSuperFieldPostfix( 7977 R visitSuperFieldPostfix(
12170 Send node, 7978 Send node, FieldElement field, IncDecOperator operator, A arg) {
12171 FieldElement field, 7979 return handleSuperFieldFieldPostfixPrefix(node, field, field, operator, arg,
12172 IncDecOperator operator, 7980 isPrefix: false);
12173 A arg) {
12174 return handleSuperFieldFieldPostfixPrefix(
12175 node, field, field, operator, arg, isPrefix: false);
12176 } 7981 }
12177 7982
12178 @override 7983 @override
12179 R visitSuperFieldPrefix( 7984 R visitSuperFieldPrefix(
12180 Send node, 7985 Send node, FieldElement field, IncDecOperator operator, A arg) {
12181 FieldElement field, 7986 return handleSuperFieldFieldPostfixPrefix(node, field, field, operator, arg,
12182 IncDecOperator operator, 7987 isPrefix: true);
12183 A arg) {
12184 return handleSuperFieldFieldPostfixPrefix(
12185 node, field, field, operator, arg, isPrefix: true);
12186 } 7988 }
12187 7989
12188 @override 7990 @override
12189 R visitSuperFieldSetterPostfix( 7991 R visitSuperFieldSetterPostfix(Send node, FieldElement field,
12190 Send node, 7992 FunctionElement setter, IncDecOperator operator, A arg) {
12191 FieldElement field,
12192 FunctionElement setter,
12193 IncDecOperator operator,
12194 A arg) {
12195 return handleSuperFieldSetterPostfixPrefix( 7993 return handleSuperFieldSetterPostfixPrefix(
12196 node, field, setter, operator, arg, isPrefix: false); 7994 node, field, setter, operator, arg,
7995 isPrefix: false);
12197 } 7996 }
12198 7997
12199 @override 7998 @override
12200 R visitSuperFieldSetterPrefix( 7999 R visitSuperFieldSetterPrefix(Send node, FieldElement field,
12201 Send node, 8000 FunctionElement setter, IncDecOperator operator, A arg) {
12202 FieldElement field,
12203 FunctionElement setter,
12204 IncDecOperator operator,
12205 A arg) {
12206 return handleSuperFieldSetterPostfixPrefix( 8001 return handleSuperFieldSetterPostfixPrefix(
12207 node, field, setter, operator, arg, isPrefix: true); 8002 node, field, setter, operator, arg,
8003 isPrefix: true);
12208 } 8004 }
12209 8005
12210 @override 8006 @override
12211 R visitSuperGetterFieldPostfix( 8007 R visitSuperGetterFieldPostfix(Send node, FunctionElement getter,
12212 Send node, 8008 FieldElement field, IncDecOperator operator, A arg) {
12213 FunctionElement getter,
12214 FieldElement field,
12215 IncDecOperator operator,
12216 A arg) {
12217 return handleSuperGetterFieldPostfixPrefix( 8009 return handleSuperGetterFieldPostfixPrefix(
12218 node, getter, field, operator, arg, isPrefix: false); 8010 node, getter, field, operator, arg,
8011 isPrefix: false);
12219 } 8012 }
12220 8013
12221 @override 8014 @override
12222 R visitSuperGetterFieldPrefix( 8015 R visitSuperGetterFieldPrefix(Send node, FunctionElement getter,
12223 Send node, 8016 FieldElement field, IncDecOperator operator, A arg) {
12224 FunctionElement getter,
12225 FieldElement field,
12226 IncDecOperator operator,
12227 A arg) {
12228 return handleSuperGetterFieldPostfixPrefix( 8017 return handleSuperGetterFieldPostfixPrefix(
12229 node, getter, field, operator, arg, isPrefix: true); 8018 node, getter, field, operator, arg,
8019 isPrefix: true);
12230 } 8020 }
12231 8021
12232 @override 8022 @override
12233 R visitSuperGetterSetterPostfix( 8023 R visitSuperGetterSetterPostfix(Send node, FunctionElement getter,
12234 Send node, 8024 FunctionElement setter, IncDecOperator operator, A arg) {
12235 FunctionElement getter,
12236 FunctionElement setter,
12237 IncDecOperator operator,
12238 A arg) {
12239 return handleSuperGetterSetterPostfixPrefix( 8025 return handleSuperGetterSetterPostfixPrefix(
12240 node, getter, setter, operator, arg, isPrefix: false); 8026 node, getter, setter, operator, arg,
8027 isPrefix: false);
12241 } 8028 }
12242 8029
12243 @override 8030 @override
12244 R visitSuperGetterSetterPrefix( 8031 R visitSuperGetterSetterPrefix(Send node, FunctionElement getter,
12245 Send node, 8032 FunctionElement setter, IncDecOperator operator, A arg) {
12246 FunctionElement getter,
12247 FunctionElement setter,
12248 IncDecOperator operator,
12249 A arg) {
12250 return handleSuperGetterSetterPostfixPrefix( 8033 return handleSuperGetterSetterPostfixPrefix(
12251 node, getter, setter, operator, arg, isPrefix: true); 8034 node, getter, setter, operator, arg,
8035 isPrefix: true);
12252 } 8036 }
12253 8037
12254 @override 8038 @override
12255 R visitSuperMethodSetterPostfix( 8039 R visitSuperMethodSetterPostfix(Send node, FunctionElement method,
12256 Send node, 8040 FunctionElement setter, IncDecOperator operator, A arg) {
12257 FunctionElement method,
12258 FunctionElement setter,
12259 IncDecOperator operator,
12260 A arg) {
12261 return handleSuperMethodSetterPostfixPrefix( 8041 return handleSuperMethodSetterPostfixPrefix(
12262 node, method, setter, operator, arg, isPrefix: false); 8042 node, method, setter, operator, arg,
8043 isPrefix: false);
12263 } 8044 }
12264 8045
12265 @override 8046 @override
12266 R visitSuperMethodSetterPrefix( 8047 R visitSuperMethodSetterPrefix(Send node, FunctionElement method,
12267 Send node, 8048 FunctionElement setter, IncDecOperator operator, A arg) {
12268 FunctionElement method,
12269 FunctionElement setter,
12270 IncDecOperator operator,
12271 A arg) {
12272 return handleSuperMethodSetterPostfixPrefix( 8049 return handleSuperMethodSetterPostfixPrefix(
12273 node, method, setter, operator, arg, isPrefix: true); 8050 node, method, setter, operator, arg,
8051 isPrefix: true);
12274 } 8052 }
12275 8053
12276 @override 8054 @override
12277 R visitSuperIndexPostfix( 8055 R visitSuperIndexPostfix(
12278 Send node, 8056 Send node,
12279 FunctionElement indexFunction, 8057 FunctionElement indexFunction,
12280 FunctionElement indexSetFunction, 8058 FunctionElement indexSetFunction,
12281 Node index, 8059 Node index,
12282 IncDecOperator operator, 8060 IncDecOperator operator,
12283 A arg) { 8061 A arg) {
12284 return handleSuperIndexPostfixPrefix( 8062 return handleSuperIndexPostfixPrefix(
12285 node, indexFunction, indexSetFunction, 8063 node, indexFunction, indexSetFunction, index, operator, arg,
12286 index, operator, arg, isPrefix: false); 8064 isPrefix: false);
12287 } 8065 }
12288 8066
12289 @override 8067 @override
12290 R visitSuperIndexPrefix( 8068 R visitSuperIndexPrefix(
12291 Send node, 8069 Send node,
12292 FunctionElement indexFunction, 8070 FunctionElement indexFunction,
12293 FunctionElement indexSetFunction, 8071 FunctionElement indexSetFunction,
12294 Node index, 8072 Node index,
12295 IncDecOperator operator, 8073 IncDecOperator operator,
12296 A arg) { 8074 A arg) {
12297 return handleSuperIndexPostfixPrefix( 8075 return handleSuperIndexPostfixPrefix(
12298 node, indexFunction, indexSetFunction, 8076 node, indexFunction, indexSetFunction, index, operator, arg,
12299 index, operator, arg, isPrefix: true); 8077 isPrefix: true);
12300 } 8078 }
12301 8079
12302 @override 8080 @override
12303 R visitUnresolvedSuperGetterIndexPostfix( 8081 R visitUnresolvedSuperGetterIndexPostfix(Send node, Element element,
12304 Send node, 8082 MethodElement setter, Node index, IncDecOperator operator, A arg) {
12305 Element element,
12306 MethodElement setter,
12307 Node index,
12308 IncDecOperator operator,
12309 A arg) {
12310 return handleUnresolvedSuperGetterIndexPostfixPrefix( 8083 return handleUnresolvedSuperGetterIndexPostfixPrefix(
12311 node, element, setter, index, operator, arg, isPrefix: false); 8084 node, element, setter, index, operator, arg,
8085 isPrefix: false);
12312 } 8086 }
12313 8087
12314 @override 8088 @override
12315 R visitUnresolvedSuperGetterIndexPrefix( 8089 R visitUnresolvedSuperGetterIndexPrefix(Send node, Element element,
12316 Send node, 8090 MethodElement setter, Node index, IncDecOperator operator, A arg) {
12317 Element element,
12318 MethodElement setter,
12319 Node index,
12320 IncDecOperator operator,
12321 A arg) {
12322 return handleUnresolvedSuperGetterIndexPostfixPrefix( 8091 return handleUnresolvedSuperGetterIndexPostfixPrefix(
12323 node, element, setter, index, operator, arg, isPrefix: true); 8092 node, element, setter, index, operator, arg,
8093 isPrefix: true);
12324 } 8094 }
12325 8095
12326 @override 8096 @override
12327 R visitUnresolvedSuperSetterIndexPostfix( 8097 R visitUnresolvedSuperSetterIndexPostfix(
12328 Send node, 8098 Send node,
12329 MethodElement indexFunction, 8099 MethodElement indexFunction,
12330 Element element, 8100 Element element,
12331 Node index, 8101 Node index,
12332 IncDecOperator operator, 8102 IncDecOperator operator,
12333 A arg) { 8103 A arg) {
12334 return handleUnresolvedSuperSetterIndexPostfixPrefix( 8104 return handleUnresolvedSuperSetterIndexPostfixPrefix(
12335 node, indexFunction, element, index, operator, arg, isPrefix: false); 8105 node, indexFunction, element, index, operator, arg,
8106 isPrefix: false);
12336 } 8107 }
12337 8108
12338 @override 8109 @override
12339 R visitUnresolvedSuperSetterIndexPrefix( 8110 R visitUnresolvedSuperSetterIndexPrefix(
12340 Send node, 8111 Send node,
12341 MethodElement indexFunction, 8112 MethodElement indexFunction,
12342 Element element, 8113 Element element,
12343 Node index, 8114 Node index,
12344 IncDecOperator operator, 8115 IncDecOperator operator,
12345 A arg) { 8116 A arg) {
12346 return handleUnresolvedSuperSetterIndexPostfixPrefix( 8117 return handleUnresolvedSuperSetterIndexPostfixPrefix(
12347 node, indexFunction, element, index, operator, arg, isPrefix: true); 8118 node, indexFunction, element, index, operator, arg,
8119 isPrefix: true);
12348 } 8120 }
12349 8121
12350 @override 8122 @override
12351 R visitUnresolvedSuperIndexPostfix( 8123 R visitUnresolvedSuperIndexPostfix(
12352 Send node, 8124 Send node, Element element, Node index, IncDecOperator operator, A arg) {
12353 Element element,
12354 Node index,
12355 IncDecOperator operator,
12356 A arg) {
12357 return handleUnresolvedSuperIndexPostfixPrefix( 8125 return handleUnresolvedSuperIndexPostfixPrefix(
12358 node, element, index, operator, arg, isPrefix: false); 8126 node, element, index, operator, arg,
8127 isPrefix: false);
12359 } 8128 }
12360 8129
12361 @override 8130 @override
12362 R visitUnresolvedSuperIndexPrefix( 8131 R visitUnresolvedSuperIndexPrefix(
12363 Send node, 8132 Send node, Element element, Node index, IncDecOperator operator, A arg) {
12364 Element element,
12365 Node index,
12366 IncDecOperator operator,
12367 A arg) {
12368 return handleUnresolvedSuperIndexPostfixPrefix( 8133 return handleUnresolvedSuperIndexPostfixPrefix(
12369 node, element, index, operator, arg, isPrefix: true); 8134 node, element, index, operator, arg,
8135 isPrefix: true);
12370 } 8136 }
12371 8137
12372 @override 8138 @override
12373 R visitFinalSuperFieldPostfix( 8139 R visitFinalSuperFieldPostfix(
12374 Send node, 8140 Send node, FieldElement field, IncDecOperator operator, A arg) {
12375 FieldElement field, 8141 return handleFinalSuperFieldPostfixPrefix(node, field, operator, arg,
12376 IncDecOperator operator, 8142 isPrefix: false);
12377 A arg) {
12378 return handleFinalSuperFieldPostfixPrefix(
12379 node, field, operator, arg, isPrefix: false);
12380 } 8143 }
12381 8144
12382 @override 8145 @override
12383 R visitFinalSuperFieldPrefix( 8146 R visitFinalSuperFieldPrefix(
12384 Send node, 8147 Send node, FieldElement field, IncDecOperator operator, A arg) {
12385 FieldElement field, 8148 return handleFinalSuperFieldPostfixPrefix(node, field, operator, arg,
12386 IncDecOperator operator, 8149 isPrefix: true);
12387 A arg) {
12388 return handleFinalSuperFieldPostfixPrefix(
12389 node, field, operator, arg, isPrefix: true);
12390 } 8150 }
12391 8151
12392 @override 8152 @override
12393 R visitSuperMethodPostfix( 8153 R visitSuperMethodPostfix(
12394 Send node, 8154 Send node, MethodElement method, IncDecOperator operator, A arg) {
12395 MethodElement method, 8155 return handleSuperMethodPostfixPrefix(node, method, operator, arg,
12396 IncDecOperator operator, 8156 isPrefix: false);
12397 A arg) {
12398 return handleSuperMethodPostfixPrefix(
12399 node, method, operator, arg, isPrefix: false);
12400 } 8157 }
12401 8158
12402 @override 8159 @override
12403 R visitSuperMethodPrefix( 8160 R visitSuperMethodPrefix(
12404 Send node, 8161 Send node, MethodElement method, IncDecOperator operator, A arg) {
12405 MethodElement method, 8162 return handleSuperMethodPostfixPrefix(node, method, operator, arg,
12406 IncDecOperator operator, 8163 isPrefix: true);
12407 A arg) {
12408 return handleSuperMethodPostfixPrefix(
12409 node, method, operator, arg, isPrefix: true);
12410 } 8164 }
12411 8165
12412 @override 8166 @override
12413 R visitUnresolvedSuperPostfix( 8167 R visitUnresolvedSuperPostfix(
12414 Send node, 8168 Send node, Element element, IncDecOperator operator, A arg) {
12415 Element element, 8169 return handleUnresolvedSuperPostfixPrefix(node, element, operator, arg,
12416 IncDecOperator operator, 8170 isPrefix: false);
12417 A arg) {
12418 return handleUnresolvedSuperPostfixPrefix(
12419 node, element, operator, arg, isPrefix: false);
12420 } 8171 }
12421 8172
12422 @override 8173 @override
12423 R visitUnresolvedSuperPrefix( 8174 R visitUnresolvedSuperPrefix(
12424 Send node, 8175 Send node, Element element, IncDecOperator operator, A arg) {
12425 Element element, 8176 return handleUnresolvedSuperPostfixPrefix(node, element, operator, arg,
12426 IncDecOperator operator, 8177 isPrefix: true);
12427 A arg) {
12428 return handleUnresolvedSuperPostfixPrefix(
12429 node, element, operator, arg, isPrefix: true);
12430 } 8178 }
12431 8179
12432 @override 8180 @override
12433 R visitUnresolvedSuperGetterPostfix( 8181 R visitUnresolvedSuperGetterPostfix(Send node, Element element,
12434 Send node, 8182 MethodElement setter, IncDecOperator operator, A arg) {
12435 Element element,
12436 MethodElement setter,
12437 IncDecOperator operator,
12438 A arg) {
12439 return handleUnresolvedSuperGetterPostfixPrefix( 8183 return handleUnresolvedSuperGetterPostfixPrefix(
12440 node, element, setter, operator, arg, isPrefix: false); 8184 node, element, setter, operator, arg,
8185 isPrefix: false);
12441 } 8186 }
12442 8187
12443 @override 8188 @override
12444 R visitUnresolvedSuperGetterPrefix( 8189 R visitUnresolvedSuperGetterPrefix(Send node, Element element,
12445 Send node, 8190 MethodElement setter, IncDecOperator operator, A arg) {
12446 Element element,
12447 MethodElement setter,
12448 IncDecOperator operator,
12449 A arg) {
12450 return handleUnresolvedSuperGetterPostfixPrefix( 8191 return handleUnresolvedSuperGetterPostfixPrefix(
12451 node, element, setter, operator, arg, isPrefix: true); 8192 node, element, setter, operator, arg,
8193 isPrefix: true);
12452 } 8194 }
12453 8195
12454 @override 8196 @override
12455 R visitUnresolvedSuperSetterPostfix( 8197 R visitUnresolvedSuperSetterPostfix(Send node, MethodElement getter,
12456 Send node, 8198 Element element, IncDecOperator operator, A arg) {
12457 MethodElement getter,
12458 Element element,
12459 IncDecOperator operator,
12460 A arg) {
12461 return handleUnresolvedSuperSetterPostfixPrefix( 8199 return handleUnresolvedSuperSetterPostfixPrefix(
12462 node, getter, element, operator, arg, isPrefix: false); 8200 node, getter, element, operator, arg,
8201 isPrefix: false);
12463 } 8202 }
12464 8203
12465 @override 8204 @override
12466 R visitUnresolvedSuperSetterPrefix( 8205 R visitUnresolvedSuperSetterPrefix(Send node, MethodElement getter,
12467 Send node, 8206 Element element, IncDecOperator operator, A arg) {
12468 MethodElement getter,
12469 Element element,
12470 IncDecOperator operator,
12471 A arg) {
12472 return handleUnresolvedSuperSetterPostfixPrefix( 8207 return handleUnresolvedSuperSetterPostfixPrefix(
12473 node, getter, element, operator, arg, isPrefix: true); 8208 node, getter, element, operator, arg,
8209 isPrefix: true);
12474 } 8210 }
12475 } 8211 }
12476 8212
12477 /// Mixin that groups the non-constant `visitXConstructorInvoke` methods by 8213 /// Mixin that groups the non-constant `visitXConstructorInvoke` methods by
12478 /// delegating calls to the `handleConstructorInvoke` method. 8214 /// delegating calls to the `handleConstructorInvoke` method.
12479 /// 8215 ///
12480 /// This mixin is useful for the cases where all constructor invocations are 8216 /// This mixin is useful for the cases where all constructor invocations are
12481 /// handled uniformly. 8217 /// handled uniformly.
12482 abstract class BaseImplementationOfNewMixin<R, A> 8218 abstract class BaseImplementationOfNewMixin<R, A>
12483 implements SemanticSendVisitor<R, A> { 8219 implements SemanticSendVisitor<R, A> {
12484 8220 R handleConstructorInvoke(NewExpression node, ConstructorElement constructor,
12485 R handleConstructorInvoke( 8221 DartType type, NodeList arguments, CallStructure callStructure, A arg);
12486 NewExpression node,
12487 ConstructorElement constructor,
12488 DartType type,
12489 NodeList arguments,
12490 CallStructure callStructure,
12491 A arg);
12492 8222
12493 R visitGenerativeConstructorInvoke( 8223 R visitGenerativeConstructorInvoke(
12494 NewExpression node, 8224 NewExpression node,
12495 ConstructorElement constructor, 8225 ConstructorElement constructor,
12496 InterfaceType type, 8226 InterfaceType type,
12497 NodeList arguments, 8227 NodeList arguments,
12498 CallStructure callStructure, 8228 CallStructure callStructure,
12499 A arg) { 8229 A arg) {
12500 return handleConstructorInvoke( 8230 return handleConstructorInvoke(
12501 node, constructor, type, arguments, callStructure, arg); 8231 node, constructor, type, arguments, callStructure, arg);
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
12533 ConstructorElement effectiveTarget, 8263 ConstructorElement effectiveTarget,
12534 InterfaceType effectiveTargetType, 8264 InterfaceType effectiveTargetType,
12535 NodeList arguments, 8265 NodeList arguments,
12536 CallStructure callStructure, 8266 CallStructure callStructure,
12537 A arg) { 8267 A arg) {
12538 return handleConstructorInvoke( 8268 return handleConstructorInvoke(
12539 node, constructor, type, arguments, callStructure, arg); 8269 node, constructor, type, arguments, callStructure, arg);
12540 } 8270 }
12541 8271
12542 @override 8272 @override
12543 R visitUnresolvedConstructorInvoke( 8273 R visitUnresolvedConstructorInvoke(NewExpression node, Element constructor,
12544 NewExpression node, 8274 DartType type, NodeList arguments, Selector selector, A arg) {
12545 Element constructor,
12546 DartType type,
12547 NodeList arguments,
12548 Selector selector,
12549 A arg) {
12550 return handleConstructorInvoke( 8275 return handleConstructorInvoke(
12551 node, constructor, type, arguments, selector.callStructure, arg); 8276 node, constructor, type, arguments, selector.callStructure, arg);
12552 } 8277 }
12553 8278
12554 @override 8279 @override
12555 R visitUnresolvedClassConstructorInvoke( 8280 R visitUnresolvedClassConstructorInvoke(NewExpression node, Element element,
12556 NewExpression node, 8281 DartType type, NodeList arguments, Selector selector, A arg) {
12557 Element element,
12558 DartType type,
12559 NodeList arguments,
12560 Selector selector,
12561 A arg) {
12562 return handleConstructorInvoke( 8282 return handleConstructorInvoke(
12563 node, element, type, arguments, selector.callStructure, arg); 8283 node, element, type, arguments, selector.callStructure, arg);
12564 } 8284 }
12565 8285
12566 @override 8286 @override
12567 R visitAbstractClassConstructorInvoke( 8287 R visitAbstractClassConstructorInvoke(
12568 NewExpression node, 8288 NewExpression node,
12569 ConstructorElement constructor, 8289 ConstructorElement constructor,
12570 InterfaceType type, 8290 InterfaceType type,
12571 NodeList arguments, 8291 NodeList arguments,
12572 CallStructure callStructure, 8292 CallStructure callStructure,
12573 A arg) { 8293 A arg) {
12574 return handleConstructorInvoke( 8294 return handleConstructorInvoke(
12575 node, constructor, type, arguments, callStructure, arg); 8295 node, constructor, type, arguments, callStructure, arg);
12576 } 8296 }
12577 8297
12578 @override 8298 @override
12579 R visitUnresolvedRedirectingFactoryConstructorInvoke( 8299 R visitUnresolvedRedirectingFactoryConstructorInvoke(
12580 NewExpression node, 8300 NewExpression node,
12581 ConstructorElement constructor, 8301 ConstructorElement constructor,
12582 InterfaceType type, 8302 InterfaceType type,
12583 NodeList arguments, 8303 NodeList arguments,
12584 CallStructure callStructure, 8304 CallStructure callStructure,
12585 A arg) { 8305 A arg) {
12586 return handleConstructorInvoke( 8306 return handleConstructorInvoke(
12587 node, constructor, type, arguments, callStructure, arg); 8307 node, constructor, type, arguments, callStructure, arg);
12588 } 8308 }
12589 } 8309 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/resolution/semantic_visitor.dart ('k') | pkg/compiler/lib/src/resolution/send_resolver.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698