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

Unified Diff: pkg/compiler/lib/src/js_emitter/new_emitter/model_emitter.dart

Issue 875413002: dart2js: add mangled-global-names embedded global to new emitter. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebase. Change comment style. Created 5 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/js_lib/shared/embedded_names.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_emitter/new_emitter/model_emitter.dart
diff --git a/pkg/compiler/lib/src/js_emitter/new_emitter/model_emitter.dart b/pkg/compiler/lib/src/js_emitter/new_emitter/model_emitter.dart
index 763acd96436f22d46d3554a08a5b3460a4645e53..8f4ac995b30eeaff36b6d391135887602c29b629 100644
--- a/pkg/compiler/lib/src/js_emitter/new_emitter/model_emitter.dart
+++ b/pkg/compiler/lib/src/js_emitter/new_emitter/model_emitter.dart
@@ -17,7 +17,8 @@ import 'package:_internal/compiler/js_lib/shared/embedded_names.dart' show
GET_TYPE_FROM_NAME,
INITIALIZE_LOADED_HUNK,
IS_HUNK_INITIALIZED,
- IS_HUNK_LOADED;
+ IS_HUNK_LOADED,
+ MANGLED_GLOBAL_NAMES;
import '../js_emitter.dart' show NativeGenerator;
import '../model.dart';
@@ -157,6 +158,9 @@ class ModelEmitter {
globals.add(emitInitializeLoadedHunk());
}
+ globals.add(new js.Property(js.string(MANGLED_GLOBAL_NAMES),
+ js.js('Object.create(null)', [])));
+
globals.add(emitGetTypeFromName());
js.ObjectInitializer globalsObject = new js.ObjectInitializer(globals);
« no previous file with comments | « no previous file | sdk/lib/_internal/compiler/js_lib/shared/embedded_names.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698