| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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 // SExpressionUnstringifier implements the inverse operation to | 5 // SExpressionUnstringifier implements the inverse operation to |
| 6 // [SExpressionStringifier]. | 6 // [SExpressionStringifier]. |
| 7 | 7 |
| 8 library sexpr_unstringifier; | 8 library sexpr_unstringifier; |
| 9 | 9 |
| 10 import 'package:compiler/implementation/constants/expressions.dart' | 10 import 'package:compiler/implementation/constants/expressions.dart' |
| (...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 495 | 495 |
| 496 Primitive recv = name2variable[tokens.read()]; | 496 Primitive recv = name2variable[tokens.read()]; |
| 497 assert(recv != null); | 497 assert(recv != null); |
| 498 | 498 |
| 499 dart_types.DartType type = new DummyNamedType(tokens.read()); | 499 dart_types.DartType type = new DummyNamedType(tokens.read()); |
| 500 | 500 |
| 501 Continuation cont = name2variable[tokens.read()]; | 501 Continuation cont = name2variable[tokens.read()]; |
| 502 assert(cont != null); | 502 assert(cont != null); |
| 503 | 503 |
| 504 tokens.consumeEnd(); | 504 tokens.consumeEnd(); |
| 505 return new TypeOperator(operator, recv, type, cont); | 505 return new TypeOperator(recv, type, cont, isTypeTest: operator == 'is'); |
| 506 } | 506 } |
| 507 | 507 |
| 508 /// (LetPrim name (primitive)) body | 508 /// (LetPrim name (primitive)) body |
| 509 LetPrim parseLetPrim() { | 509 LetPrim parseLetPrim() { |
| 510 tokens.consumeStart(LET_PRIM); | 510 tokens.consumeStart(LET_PRIM); |
| 511 | 511 |
| 512 // name | 512 // name |
| 513 String name = tokens.read(); | 513 String name = tokens.read(); |
| 514 | 514 |
| 515 // (primitive) | 515 // (primitive) |
| (...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 678 return new ReifyTypeVar(type); | 678 return new ReifyTypeVar(type); |
| 679 } | 679 } |
| 680 | 680 |
| 681 /// (This) | 681 /// (This) |
| 682 This parseThis() { | 682 This parseThis() { |
| 683 tokens.consumeStart(THIS); | 683 tokens.consumeStart(THIS); |
| 684 tokens.consumeEnd(); | 684 tokens.consumeEnd(); |
| 685 return new This(); | 685 return new This(); |
| 686 } | 686 } |
| 687 } | 687 } |
| OLD | NEW |