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 dart2js.js_emitter.full_emitter; | 5 library dart2js.js_emitter.full_emitter; |
6 | 6 |
7 import 'dart:collection' show HashMap; | 7 import 'dart:collection' show HashMap; |
8 import 'dart:convert'; | 8 import 'dart:convert'; |
9 | 9 |
10 import 'package:js_runtime/shared/embedded_names.dart' as embeddedNames; | 10 import 'package:js_runtime/shared/embedded_names.dart' as embeddedNames; |
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
117 /// True if [ContainerBuilder.addMemberMethodFromInfo] used "structured info", | 117 /// True if [ContainerBuilder.addMemberMethodFromInfo] used "structured info", |
118 /// that is, some function was needed for reflection, had stubs, or had a | 118 /// that is, some function was needed for reflection, had stubs, or had a |
119 /// super alias. | 119 /// super alias. |
120 bool needsStructuredMemberInfo = false; | 120 bool needsStructuredMemberInfo = false; |
121 | 121 |
122 final Namer namer; | 122 final Namer namer; |
123 ConstantEmitter constantEmitter; | 123 ConstantEmitter constantEmitter; |
124 NativeEmitter get nativeEmitter => task.nativeEmitter; | 124 NativeEmitter get nativeEmitter => task.nativeEmitter; |
125 TypeTestRegistry get typeTestRegistry => task.typeTestRegistry; | 125 TypeTestRegistry get typeTestRegistry => task.typeTestRegistry; |
126 CommonElements get commonElements => _closedWorld.commonElements; | 126 CommonElements get commonElements => _closedWorld.commonElements; |
127 ElementEnvironment get _elementEnvironment => compiler.elementEnvironment; | 127 ElementEnvironment get _elementEnvironment => _closedWorld.elementEnvironment; |
128 | 128 |
129 // The full code that is written to each hunk part-file. | 129 // The full code that is written to each hunk part-file. |
130 Map<OutputUnit, CodeOutput> outputBuffers = new Map<OutputUnit, CodeOutput>(); | 130 Map<OutputUnit, CodeOutput> outputBuffers = new Map<OutputUnit, CodeOutput>(); |
131 | 131 |
132 String classesCollector; | 132 String classesCollector; |
133 final Map<jsAst.Name, String> mangledFieldNames = | 133 final Map<jsAst.Name, String> mangledFieldNames = |
134 new HashMap<jsAst.Name, String>(); | 134 new HashMap<jsAst.Name, String>(); |
135 final Map<jsAst.Name, String> mangledGlobalFieldNames = | 135 final Map<jsAst.Name, String> mangledGlobalFieldNames = |
136 new HashMap<jsAst.Name, String>(); | 136 new HashMap<jsAst.Name, String>(); |
137 final Set<jsAst.Name> recordedMangledNames = new Set<jsAst.Name>(); | 137 final Set<jsAst.Name> recordedMangledNames = new Set<jsAst.Name>(); |
(...skipping 1783 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1921 // data. | 1921 // data. |
1922 mapping["_comment"] = "This mapping shows which compiled `.js` files are " | 1922 mapping["_comment"] = "This mapping shows which compiled `.js` files are " |
1923 "needed for a given deferred library import."; | 1923 "needed for a given deferred library import."; |
1924 mapping.addAll(compiler.deferredLoadTask.computeDeferredMap()); | 1924 mapping.addAll(compiler.deferredLoadTask.computeDeferredMap()); |
1925 compiler.outputProvider( | 1925 compiler.outputProvider( |
1926 compiler.options.deferredMapUri.path, '', OutputType.info) | 1926 compiler.options.deferredMapUri.path, '', OutputType.info) |
1927 ..add(const JsonEncoder.withIndent(" ").convert(mapping)) | 1927 ..add(const JsonEncoder.withIndent(" ").convert(mapping)) |
1928 ..close(); | 1928 ..close(); |
1929 } | 1929 } |
1930 } | 1930 } |
OLD | NEW |