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

Unified Diff: lib/runtime/dart/_isolate_helper.js

Issue 1487213002: Special-case top-level final JS fields. (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: rebased Created 5 years 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 | lib/runtime/dart/_js_mirrors.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/runtime/dart/_isolate_helper.js
diff --git a/lib/runtime/dart/_isolate_helper.js b/lib/runtime/dart/_isolate_helper.js
index 5606797fd67382611b5d17a8df8eec444f770444..224cb4ac20a18b4db876d3990920a1f8a4100fac 100644
--- a/lib/runtime/dart/_isolate_helper.js
+++ b/lib/runtime/dart/_isolate_helper.js
@@ -916,14 +916,10 @@ dart_library.library('dart/_isolate_helper', null, /* Imports */[
constructors: () => ({_IsolateEvent: [_IsolateEvent, [_IsolateContext, core.Function, core.String]]}),
methods: () => ({process: [dart.void, []]})
});
- dart.defineLazyProperties(exports, {
- get _global() {
- return typeof global == 'undefined' ? self : global;
- }
- });
+ const _global = typeof global == 'undefined' ? self : global;
class _MainManagerStub extends core.Object {
postMessage(msg) {
- exports._global.postMessage(msg);
+ _global.postMessage(msg);
}
}
dart.setSignature(_MainManagerStub, {
@@ -933,13 +929,13 @@ dart_library.library('dart/_isolate_helper', null, /* Imports */[
const _SPAWN_FAILED_SIGNAL = "spawn failed";
dart.copyProperties(exports, {
get globalWindow() {
- return exports._global.window;
+ return _global.window;
},
get globalWorker() {
- return exports._global.Worker;
+ return _global.Worker;
},
get globalPostMessageDefined() {
- return !!exports._global.postMessage;
+ return !!_global.postMessage;
}
});
const _MainFunction = dart.typedef('_MainFunction', () => dart.functionType(dart.dynamic, []));
« no previous file with comments | « no previous file | lib/runtime/dart/_js_mirrors.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698