Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(165)

Unified Diff: sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart

Issue 141023007: Emit the type test support code to the right output unit. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Respond to review. Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | sdk/lib/_internal/compiler/implementation/js_emitter/type_test_emitter.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart
diff --git a/sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart b/sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart
index 93241b7f705585424d66301d5b8c4b585d3c8c00..2f81f2d981126de5a93d3f680db7a081043b5261 100644
--- a/sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart
+++ b/sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart
@@ -1381,16 +1381,15 @@ mainBuffer.add(r'''
emitFinishClassesInvocationIfNecessary(mainBuffer);
classesCollector = oldClassesCollector;
}
-
- typeTestEmitter.emitRuntimeTypeSupport(mainBuffer);
+ OutputUnit mainOutputUnit = compiler.deferredLoadTask.mainOutputUnit;
+ typeTestEmitter.emitRuntimeTypeSupport(mainBuffer, mainOutputUnit);
interceptorEmitter.emitGetInterceptorMethods(mainBuffer);
interceptorEmitter.emitOneShotInterceptors(mainBuffer);
// Constants in checked mode call into RTI code to set type information
// which may need getInterceptor (and one-shot interceptor) methods, so
// we have to make sure that [emitGetInterceptorMethods] and
// [emitOneShotInterceptors] have been called.
- emitCompileTimeConstants(
- mainBuffer, compiler.deferredLoadTask.mainOutputUnit);
+ emitCompileTimeConstants(mainBuffer, mainOutputUnit);
// We write a javascript mapping from DeferredLibrary elements
// (really their String argument) to the js hunk to load.
@@ -1569,6 +1568,8 @@ if (typeof $printHelperName === "function") {
classesCollector = oldClassesCollector;
+ typeTestEmitter.emitRuntimeTypeSupport(buffer, outputUnit);
+
emitCompileTimeConstants(buffer, outputUnit);
String code = buffer.getText();
« no previous file with comments | « no previous file | sdk/lib/_internal/compiler/implementation/js_emitter/type_test_emitter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698