| OLD | NEW |
| 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 | 4 |
| 5 // IrNodes are kept in a separate library to have precise control over their | 5 // IrNodes are kept in a separate library to have precise control over their |
| 6 // dependencies on other parts of the system. | 6 // dependencies on other parts of the system. |
| 7 library dart2js.ir_nodes; | 7 library dart2js.ir_nodes; |
| 8 | 8 |
| 9 import '../constants/expressions.dart'; | 9 import '../constants/expressions.dart'; |
| 10 import '../constants/values.dart' as values show ConstantValue; | 10 import '../constants/values.dart' as values show ConstantValue; |
| (...skipping 550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 561 this.defaultParameterValues); | 561 this.defaultParameterValues); |
| 562 | 562 |
| 563 FunctionDefinition.abstract(this.element, | 563 FunctionDefinition.abstract(this.element, |
| 564 this.parameters, | 564 this.parameters, |
| 565 this.defaultParameterValues) | 565 this.defaultParameterValues) |
| 566 : this.returnContinuation = null, | 566 : this.returnContinuation = null, |
| 567 this.localConstants = const <ConstDeclaration>[]; | 567 this.localConstants = const <ConstDeclaration>[]; |
| 568 | 568 |
| 569 accept(Visitor visitor) => visitor.visitFunctionDefinition(this); | 569 accept(Visitor visitor) => visitor.visitFunctionDefinition(this); |
| 570 | 570 |
| 571 /// Returns `true` if this function is abstract. | 571 /// Returns `true` if this function is abstract or external. |
| 572 /// | 572 /// |
| 573 /// If `true`, [body] and [returnContinuation] are `null` and [localConstants] | 573 /// If `true`, [body] and [returnContinuation] are `null` and [localConstants] |
| 574 /// is empty. | 574 /// is empty. |
| 575 bool get isAbstract => body == null; | 575 bool get isAbstract => body == null; |
| 576 } | 576 } |
| 577 | 577 |
| 578 List<Reference<Primitive>> _referenceList(Iterable<Primitive> definitions) { | 578 List<Reference<Primitive>> _referenceList(Iterable<Primitive> definitions) { |
| 579 return definitions.map((e) => new Reference<Primitive>(e)).toList(); | 579 return definitions.map((e) => new Reference<Primitive>(e)).toList(); |
| 580 } | 580 } |
| 581 | 581 |
| (...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 945 release(node.parameters[i]); | 945 release(node.parameters[i]); |
| 946 } | 946 } |
| 947 } | 947 } |
| 948 | 948 |
| 949 void visitIsTrue(IsTrue node) { | 949 void visitIsTrue(IsTrue node) { |
| 950 visitReference(node.value); | 950 visitReference(node.value); |
| 951 } | 951 } |
| 952 | 952 |
| 953 } | 953 } |
| 954 | 954 |
| OLD | NEW |