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

Side by Side Diff: pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart

Issue 1521553003: dart2js cps: Replace GetLazyStatic with GetStatic. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Remove obsolete comment Created 5 years 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/tree_ir/tree_ir_builder.dart ('k') | no next file » | 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_nodes; 5 library tree_ir_nodes;
6 6
7 import '../constants/values.dart' as values; 7 import '../constants/values.dart' as values;
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 726 matching lines...) Expand 10 before | Expand all | Expand 10 after
737 DartType dartType; 737 DartType dartType;
738 738
739 GetTypeTestProperty(this.object, this.dartType); 739 GetTypeTestProperty(this.object, this.dartType);
740 740
741 accept(ExpressionVisitor visitor) => 741 accept(ExpressionVisitor visitor) =>
742 visitor.visitGetTypeTestProperty(this); 742 visitor.visitGetTypeTestProperty(this);
743 accept1(ExpressionVisitor1 visitor, arg) => 743 accept1(ExpressionVisitor1 visitor, arg) =>
744 visitor.visitGetTypeTestProperty(this, arg); 744 visitor.visitGetTypeTestProperty(this, arg);
745 } 745 }
746 746
747
748 /// Read the value of a field, possibly provoking its initializer to evaluate, 747 /// Read the value of a field, possibly provoking its initializer to evaluate,
749 /// or tear off a static method. 748 /// or tear off a static method.
750 class GetStatic extends Expression { 749 class GetStatic extends Expression {
751 Element element; 750 Element element;
752 SourceInformation sourceInformation; 751 SourceInformation sourceInformation;
752 bool useLazyGetter = false;
753 753
754 GetStatic(this.element, this.sourceInformation); 754 GetStatic(this.element, this.sourceInformation);
755 755
756 GetStatic.lazy(this.element, this.sourceInformation) : useLazyGetter = true;
757
756 accept(ExpressionVisitor visitor) => visitor.visitGetStatic(this); 758 accept(ExpressionVisitor visitor) => visitor.visitGetStatic(this);
757 accept1(ExpressionVisitor1 visitor, arg) => visitor.visitGetStatic(this, arg); 759 accept1(ExpressionVisitor1 visitor, arg) => visitor.visitGetStatic(this, arg);
758 } 760 }
759 761
760 class SetStatic extends Expression { 762 class SetStatic extends Expression {
761 Element element; 763 Element element;
762 Expression value; 764 Expression value;
763 SourceInformation sourceInformation; 765 SourceInformation sourceInformation;
764 766
765 SetStatic(this.element, this.value, this.sourceInformation); 767 SetStatic(this.element, this.value, this.sourceInformation);
(...skipping 834 matching lines...) Expand 10 before | Expand all | Expand 10 after
1600 1602
1601 /// Number of uses of the current fallthrough target. 1603 /// Number of uses of the current fallthrough target.
1602 int get useCount => _stack.last.useCount; 1604 int get useCount => _stack.last.useCount;
1603 1605
1604 /// Indicate that a statement will fall through to the current fallthrough 1606 /// Indicate that a statement will fall through to the current fallthrough
1605 /// target. 1607 /// target.
1606 void use() { 1608 void use() {
1607 ++_stack.last.useCount; 1609 ++_stack.last.useCount;
1608 } 1610 }
1609 } 1611 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/tree_ir/tree_ir_builder.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698