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 library dart_tree; | 5 library dart_tree; |
6 | 6 |
7 import '../dart2jslib.dart' as dart2js; | 7 import '../dart2jslib.dart' as dart2js; |
8 import '../elements/elements.dart'; | 8 import '../elements/elements.dart'; |
9 import '../universe/universe.dart'; | 9 import '../universe/universe.dart'; |
10 import '../ir/ir_nodes.dart' as ir; | 10 import '../ir/ir_nodes.dart' as ir; |
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
140 | 140 |
141 InvokeSuperMethod(this.selector, this.arguments) ; | 141 InvokeSuperMethod(this.selector, this.arguments) ; |
142 | 142 |
143 accept(Visitor visitor) => visitor.visitInvokeSuperMethod(this); | 143 accept(Visitor visitor) => visitor.visitInvokeSuperMethod(this); |
144 } | 144 } |
145 | 145 |
146 /** | 146 /** |
147 * Call to a factory or generative constructor. | 147 * Call to a factory or generative constructor. |
148 */ | 148 */ |
149 class InvokeConstructor extends Expression implements Invoke { | 149 class InvokeConstructor extends Expression implements Invoke { |
150 final GenericType type; | 150 final DartType type; |
151 final FunctionElement target; | 151 final FunctionElement target; |
152 final List<Expression> arguments; | 152 final List<Expression> arguments; |
153 final Selector selector; | 153 final Selector selector; |
154 final dart2js.Constant constant; | 154 final dart2js.Constant constant; |
155 | 155 |
156 InvokeConstructor(this.type, this.target, this.selector, this.arguments, | 156 InvokeConstructor(this.type, this.target, this.selector, this.arguments, |
157 [this.constant]); | 157 [this.constant]); |
158 | 158 |
159 ClassElement get targetClass => target.enclosingElement; | 159 ClassElement get targetClass => target.enclosingElement; |
160 | 160 |
(...skipping 1824 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1985 } | 1985 } |
1986 } | 1986 } |
1987 | 1987 |
1988 /// Destructively updates each entry of [l] with the result of visiting it. | 1988 /// Destructively updates each entry of [l] with the result of visiting it. |
1989 void _rewriteList(List<Expression> l) { | 1989 void _rewriteList(List<Expression> l) { |
1990 for (int i = 0; i < l.length; i++) { | 1990 for (int i = 0; i < l.length; i++) { |
1991 l[i] = visitExpression(l[i]); | 1991 l[i] = visitExpression(l[i]); |
1992 } | 1992 } |
1993 } | 1993 } |
1994 } | 1994 } |
OLD | NEW |