| 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 library dart2js.ir_builder; | 5 library dart2js.ir_builder; |
| 6 | 6 |
| 7 import '../closure.dart' hide ClosureScope; | 7 import '../closure.dart' hide ClosureScope; |
| 8 import '../common.dart'; | 8 import '../common.dart'; |
| 9 import '../common/names.dart' show | 9 import '../common/names.dart' show |
| 10 Names, | 10 Names, |
| (...skipping 663 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 674 buildThis(), target, selector, arguments, sourceInformation)); | 674 buildThis(), target, selector, arguments, sourceInformation)); |
| 675 } | 675 } |
| 676 | 676 |
| 677 ir.Primitive _buildInvokeDynamic(ir.Primitive receiver, | 677 ir.Primitive _buildInvokeDynamic(ir.Primitive receiver, |
| 678 Selector selector, | 678 Selector selector, |
| 679 TypeMask mask, | 679 TypeMask mask, |
| 680 List<ir.Primitive> arguments, | 680 List<ir.Primitive> arguments, |
| 681 SourceInformation sourceInformation) { | 681 SourceInformation sourceInformation) { |
| 682 assert(isOpen); | 682 assert(isOpen); |
| 683 return addPrimitive(new ir.InvokeMethod( | 683 return addPrimitive(new ir.InvokeMethod( |
| 684 receiver, selector, mask, arguments, sourceInformation)); | 684 receiver, selector, mask, arguments, |
| 685 sourceInformation: sourceInformation)); |
| 685 } | 686 } |
| 686 | 687 |
| 687 ir.Primitive _buildInvokeCall(ir.Primitive target, | 688 ir.Primitive _buildInvokeCall(ir.Primitive target, |
| 688 CallStructure callStructure, | 689 CallStructure callStructure, |
| 689 TypeMask mask, | 690 TypeMask mask, |
| 690 List<ir.Definition> arguments, | 691 List<ir.Definition> arguments, |
| 691 {SourceInformation sourceInformation}) { | 692 {SourceInformation sourceInformation}) { |
| 692 Selector selector = callStructure.callSelector; | 693 Selector selector = callStructure.callSelector; |
| 693 return _buildInvokeDynamic( | 694 return _buildInvokeDynamic( |
| 694 target, selector, mask, arguments, sourceInformation); | 695 target, selector, mask, arguments, sourceInformation); |
| (...skipping 2221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2916 } | 2917 } |
| 2917 | 2918 |
| 2918 class SwitchCaseInfo { | 2919 class SwitchCaseInfo { |
| 2919 final List<ir.Primitive> constants = <ir.Primitive>[]; | 2920 final List<ir.Primitive> constants = <ir.Primitive>[]; |
| 2920 final SubbuildFunction buildBody; | 2921 final SubbuildFunction buildBody; |
| 2921 | 2922 |
| 2922 SwitchCaseInfo(this.buildBody); | 2923 SwitchCaseInfo(this.buildBody); |
| 2923 | 2924 |
| 2924 void addConstant(ir.Primitive constant) => constants.add(constant); | 2925 void addConstant(ir.Primitive constant) => constants.add(constant); |
| 2925 } | 2926 } |
| OLD | NEW |