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

Side by Side Diff: pkg/compiler/lib/src/tree_ir/tree_ir_builder.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
« no previous file with comments | « pkg/compiler/lib/src/ssa/builder.dart ('k') | pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 library tree_ir_builder; 5 library tree_ir_builder;
6 6
7 import '../dart2jslib.dart' as dart2js; 7 import '../dart2jslib.dart' as dart2js;
8 import '../dart_types.dart'; 8 import '../dart_types.dart';
9 import '../elements/elements.dart'; 9 import '../elements/elements.dart';
10 import '../cps_ir/cps_ir_nodes.dart' as cps_ir; 10 import '../cps_ir/cps_ir_nodes.dart' as cps_ir;
(...skipping 472 matching lines...) Expand 10 before | Expand all | Expand 10 after
483 thenStatement = 483 thenStatement =
484 cont.hasExactlyOneUse ? visit(cont.body) : new Break(labels[cont]); 484 cont.hasExactlyOneUse ? visit(cont.body) : new Break(labels[cont]);
485 cont = node.falseContinuation.definition; 485 cont = node.falseContinuation.definition;
486 assert(cont.parameters.isEmpty); 486 assert(cont.parameters.isEmpty);
487 elseStatement = 487 elseStatement =
488 cont.hasExactlyOneUse ? visit(cont.body) : new Break(labels[cont]); 488 cont.hasExactlyOneUse ? visit(cont.body) : new Break(labels[cont]);
489 return new If(condition, thenStatement, elseStatement); 489 return new If(condition, thenStatement, elseStatement);
490 } 490 }
491 491
492 Expression visitConstant(cps_ir.Constant node) { 492 Expression visitConstant(cps_ir.Constant node) {
493 return new Constant(node.expression); 493 return new Constant(node.expression, node.value);
494 } 494 }
495 495
496 Expression visitLiteralList(cps_ir.LiteralList node) { 496 Expression visitLiteralList(cps_ir.LiteralList node) {
497 return new LiteralList( 497 return new LiteralList(
498 node.type, 498 node.type,
499 translateArguments(node.values)); 499 translateArguments(node.values));
500 } 500 }
501 501
502 Expression visitLiteralMap(cps_ir.LiteralMap node) { 502 Expression visitLiteralMap(cps_ir.LiteralMap node) {
503 return new LiteralMap( 503 return new LiteralMap(
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
571 571
572 Statement visitSetStatic(cps_ir.SetStatic node) { 572 Statement visitSetStatic(cps_ir.SetStatic node) {
573 SetStatic setStatic = new SetStatic( 573 SetStatic setStatic = new SetStatic(
574 node.element, 574 node.element,
575 getVariableUse(node.value), 575 getVariableUse(node.value),
576 node.sourceInformation); 576 node.sourceInformation);
577 return new ExpressionStatement(setStatic, visit(node.body)); 577 return new ExpressionStatement(setStatic, visit(node.body));
578 } 578 }
579 } 579 }
580 580
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/ssa/builder.dart ('k') | pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698