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

Side by Side Diff: pkg/compiler/lib/src/cps_ir/cps_ir_nodes.dart

Issue 1148343004: Remove ConstantExpression.value (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Update comments. Created 5 years, 6 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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 library dart2js.ir_nodes; 4 library dart2js.ir_nodes;
5 5
6 import '../constants/expressions.dart'; 6 import '../constants/expressions.dart';
7 import '../constants/values.dart' as values show ConstantValue; 7 import '../constants/values.dart' as values show ConstantValue;
8 import '../dart_types.dart' show DartType, InterfaceType, TypeVariableType; 8 import '../dart_types.dart' show DartType, InterfaceType, TypeVariableType;
9 import '../elements/elements.dart'; 9 import '../elements/elements.dart';
10 import '../io/source_information.dart' show SourceInformation; 10 import '../io/source_information.dart' show SourceInformation;
(...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after
663 final List<Reference<Primitive>> arguments; 663 final List<Reference<Primitive>> arguments;
664 664
665 CreateInvocationMirror(this.selector, List<Primitive> arguments) 665 CreateInvocationMirror(this.selector, List<Primitive> arguments)
666 : this.arguments = _referenceList(arguments); 666 : this.arguments = _referenceList(arguments);
667 667
668 accept(Visitor visitor) => visitor.visitCreateInvocationMirror(this); 668 accept(Visitor visitor) => visitor.visitCreateInvocationMirror(this);
669 } 669 }
670 670
671 class Constant extends Primitive { 671 class Constant extends Primitive {
672 final ConstantExpression expression; 672 final ConstantExpression expression;
673 final values.ConstantValue value;
673 674
674 Constant(this.expression); 675 Constant(this.expression, this.value);
675
676 values.ConstantValue get value => expression.value;
677 676
678 accept(Visitor visitor) => visitor.visitConstant(this); 677 accept(Visitor visitor) => visitor.visitConstant(this);
679 } 678 }
680 679
681 class LiteralList extends Primitive { 680 class LiteralList extends Primitive {
682 /// The List type being created; this is not the type argument. 681 /// The List type being created; this is not the type argument.
683 final InterfaceType type; 682 final InterfaceType type;
684 final List<Reference<Primitive>> values; 683 final List<Reference<Primitive>> values;
685 684
686 LiteralList(this.type, List<Primitive> values) 685 LiteralList(this.type, List<Primitive> values)
(...skipping 478 matching lines...) Expand 10 before | Expand all | Expand 10 after
1165 processNonTailThrow(node); 1164 processNonTailThrow(node);
1166 processReference(node.value); 1165 processReference(node.value);
1167 } 1166 }
1168 1167
1169 processCreateInvocationMirror(CreateInvocationMirror node) {} 1168 processCreateInvocationMirror(CreateInvocationMirror node) {}
1170 visitCreateInvocationMirror(CreateInvocationMirror node) { 1169 visitCreateInvocationMirror(CreateInvocationMirror node) {
1171 processCreateInvocationMirror(node); 1170 processCreateInvocationMirror(node);
1172 node.arguments.forEach(processReference); 1171 node.arguments.forEach(processReference);
1173 } 1172 }
1174 } 1173 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/cps_ir/cps_ir_builder_task.dart ('k') | pkg/compiler/lib/src/cps_ir/cps_ir_nodes_sexpr.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698