| 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/src/constants/expressions.dart'; | 10 import 'package:compiler/src/constants/expressions.dart'; |
| 11 import 'package:compiler/src/constants/values.dart'; | 11 import 'package:compiler/src/constants/values.dart'; |
| 12 import 'package:compiler/src/dart_types.dart' as dart_types | 12 import 'package:compiler/src/dart_types.dart' as dart_types |
| 13 show DartType; | 13 show DartType; |
| 14 import 'package:compiler/src/diagnostics/messages.dart' |
| 15 show MessageKind; |
| 14 import 'package:compiler/src/elements/elements.dart'; | 16 import 'package:compiler/src/elements/elements.dart'; |
| 15 import 'package:compiler/src/elements/modelx.dart' | 17 import 'package:compiler/src/elements/modelx.dart' |
| 16 show ErroneousElementX, TypeVariableElementX; | 18 show ErroneousElementX, TypeVariableElementX; |
| 17 import 'package:compiler/src/messages.dart' | |
| 18 show MessageKind; | |
| 19 import 'package:compiler/src/tree/tree.dart' show LiteralDartString; | 19 import 'package:compiler/src/tree/tree.dart' show LiteralDartString; |
| 20 import 'package:compiler/src/universe/universe.dart' | 20 import 'package:compiler/src/universe/universe.dart' |
| 21 show Selector, SelectorKind, CallStructure; | 21 show Selector, SelectorKind, CallStructure; |
| 22 import 'package:compiler/src/cps_ir/cps_ir_nodes.dart'; | 22 import 'package:compiler/src/cps_ir/cps_ir_nodes.dart'; |
| 23 | 23 |
| 24 /// Used whenever a node constructed by [SExpressionUnstringifier] needs a | 24 /// Used whenever a node constructed by [SExpressionUnstringifier] needs a |
| 25 /// named entity. | 25 /// named entity. |
| 26 class DummyEntity extends Entity { | 26 class DummyEntity extends Entity { |
| 27 final String name; | 27 final String name; |
| 28 DummyEntity(this.name); | 28 DummyEntity(this.name); |
| (...skipping 845 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 874 tokens.consumeStart(SET_FIELD); | 874 tokens.consumeStart(SET_FIELD); |
| 875 | 875 |
| 876 Primitive object = name2variable[tokens.read()]; | 876 Primitive object = name2variable[tokens.read()]; |
| 877 Element field = new DummyElement(tokens.read()); | 877 Element field = new DummyElement(tokens.read()); |
| 878 Primitive value = name2variable[tokens.read()]; | 878 Primitive value = name2variable[tokens.read()]; |
| 879 | 879 |
| 880 tokens.consumeEnd(); | 880 tokens.consumeEnd(); |
| 881 return new SetField(object, field, value); | 881 return new SetField(object, field, value); |
| 882 } | 882 } |
| 883 } | 883 } |
| OLD | NEW |