| 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_task; | 5 library dart2js.ir_builder_task; |
| 6 | 6 |
| 7 import '../closure.dart' as closurelib; | 7 import '../closure.dart' as closurelib; |
| 8 import '../closure.dart' hide ClosureScope; | 8 import '../closure.dart' hide ClosureScope; |
| 9 import '../common.dart'; | 9 import '../common.dart'; |
| 10 import '../common/names.dart' show | 10 import '../common/names.dart' show |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 FunctionSignatureX; | 23 FunctionSignatureX; |
| 24 import '../io/source_information.dart'; | 24 import '../io/source_information.dart'; |
| 25 import '../js_backend/backend_helpers.dart' show | 25 import '../js_backend/backend_helpers.dart' show |
| 26 BackendHelpers; | 26 BackendHelpers; |
| 27 import '../js_backend/js_backend.dart' show | 27 import '../js_backend/js_backend.dart' show |
| 28 JavaScriptBackend, | 28 JavaScriptBackend, |
| 29 SyntheticConstantKind; | 29 SyntheticConstantKind; |
| 30 import '../resolution/tree_elements.dart' show | 30 import '../resolution/tree_elements.dart' show |
| 31 TreeElements; | 31 TreeElements; |
| 32 import '../resolution/semantic_visitor.dart'; | 32 import '../resolution/semantic_visitor.dart'; |
| 33 import '../resolution/send_resolver.dart' show | |
| 34 SendResolverMixin; | |
| 35 import '../resolution/operators.dart' as op; | 33 import '../resolution/operators.dart' as op; |
| 36 import '../tree/tree.dart' as ast; | 34 import '../tree/tree.dart' as ast; |
| 37 import '../types/types.dart' show | 35 import '../types/types.dart' show |
| 38 TypeMask; | 36 TypeMask; |
| 39 import '../universe/call_structure.dart' show | 37 import '../universe/call_structure.dart' show |
| 40 CallStructure; | 38 CallStructure; |
| 41 import '../universe/selector.dart' show | 39 import '../universe/selector.dart' show |
| 42 Selector; | 40 Selector; |
| 43 import '../constants/values.dart' show | 41 import '../constants/values.dart' show |
| 44 ConstantValue; | 42 ConstantValue; |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 /// The visitor has an [IrBuilder] which contains an IR fragment to build upon | 110 /// The visitor has an [IrBuilder] which contains an IR fragment to build upon |
| 113 /// and the current reaching definition of local variables. | 111 /// and the current reaching definition of local variables. |
| 114 /// | 112 /// |
| 115 /// Visiting a statement or expression extends the IR builder's fragment. | 113 /// Visiting a statement or expression extends the IR builder's fragment. |
| 116 /// For expressions, the primitive holding the resulting value is returned. | 114 /// For expressions, the primitive holding the resulting value is returned. |
| 117 /// For statements, `null` is returned. | 115 /// For statements, `null` is returned. |
| 118 // TODO(johnniwinther): Implement [SemanticDeclVisitor]. | 116 // TODO(johnniwinther): Implement [SemanticDeclVisitor]. |
| 119 abstract class IrBuilderVisitor extends ast.Visitor<ir.Primitive> | 117 abstract class IrBuilderVisitor extends ast.Visitor<ir.Primitive> |
| 120 with IrBuilderMixin<ast.Node>, | 118 with IrBuilderMixin<ast.Node>, |
| 121 SemanticSendResolvedMixin<ir.Primitive, dynamic>, | 119 SemanticSendResolvedMixin<ir.Primitive, dynamic>, |
| 122 SendResolverMixin, | |
| 123 ErrorBulkMixin<ir.Primitive, dynamic>, | 120 ErrorBulkMixin<ir.Primitive, dynamic>, |
| 124 BaseImplementationOfStaticsMixin<ir.Primitive, dynamic>, | 121 BaseImplementationOfStaticsMixin<ir.Primitive, dynamic>, |
| 125 BaseImplementationOfLocalsMixin<ir.Primitive, dynamic>, | 122 BaseImplementationOfLocalsMixin<ir.Primitive, dynamic>, |
| 126 BaseImplementationOfDynamicsMixin<ir.Primitive, dynamic>, | 123 BaseImplementationOfDynamicsMixin<ir.Primitive, dynamic>, |
| 127 BaseImplementationOfConstantsMixin<ir.Primitive, dynamic>, | 124 BaseImplementationOfConstantsMixin<ir.Primitive, dynamic>, |
| 128 BaseImplementationOfNewMixin<ir.Primitive, dynamic>, | 125 BaseImplementationOfNewMixin<ir.Primitive, dynamic>, |
| 129 BaseImplementationOfCompoundsMixin<ir.Primitive, dynamic>, | 126 BaseImplementationOfCompoundsMixin<ir.Primitive, dynamic>, |
| 130 BaseImplementationOfSetIfNullsMixin<ir.Primitive, dynamic>, | 127 BaseImplementationOfSetIfNullsMixin<ir.Primitive, dynamic>, |
| 131 BaseImplementationOfIndexCompoundsMixin<ir.Primitive, dynamic> | 128 BaseImplementationOfIndexCompoundsMixin<ir.Primitive, dynamic> |
| 132 implements SemanticSendVisitor<ir.Primitive, dynamic> { | 129 implements SemanticSendVisitor<ir.Primitive, dynamic> { |
| (...skipping 3466 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3599 if (compiler.backend.isForeign(function)) { | 3596 if (compiler.backend.isForeign(function)) { |
| 3600 return handleForeignCode(node, function, argumentList, callStructure); | 3597 return handleForeignCode(node, function, argumentList, callStructure); |
| 3601 } else { | 3598 } else { |
| 3602 return irBuilder.buildStaticFunctionInvocation(function, callStructure, | 3599 return irBuilder.buildStaticFunctionInvocation(function, callStructure, |
| 3603 translateStaticArguments(argumentList, function, callStructure), | 3600 translateStaticArguments(argumentList, function, callStructure), |
| 3604 sourceInformation: | 3601 sourceInformation: |
| 3605 sourceInformationBuilder.buildCall(node, node.selector)); | 3602 sourceInformationBuilder.buildCall(node, node.selector)); |
| 3606 } | 3603 } |
| 3607 } | 3604 } |
| 3608 } | 3605 } |
| OLD | NEW |