diff options
author | Alon Zakai <alonzakai@gmail.com> | 2011-11-30 14:48:41 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2011-11-30 15:35:51 -0800 |
commit | 49660048bffde0caa891da7ebfe1466d15c6e930 (patch) | |
tree | 222dd165aced4141ea914a04b03372d904612d59 /src/postamble.js | |
parent | c2e49c8b6bbd881f28ad5379e60a8938cbac23cc (diff) |
refactor compiler to allow future batching of types and globals. move postsets from run() to the toplevel to boost performance and simplify compilation. fix various bugs that were noticed during this
Diffstat (limited to 'src/postamble.js')
-rw-r--r-- | src/postamble.js | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/postamble.js b/src/postamble.js index f1d48ead..c8fd44bd 100644 --- a/src/postamble.js +++ b/src/postamble.js @@ -20,11 +20,11 @@ Module.callMain = function callMain(args) { return _main(argc, argv, 0); } +{{GLOBAL_VARS}} + function run(args) { args = args || Module['arguments']; -{{GLOBAL_VARS}} - __globalConstructor__(); var ret = null; @@ -38,6 +38,11 @@ Module['run'] = run; // {{PRE_RUN_ADDITIONS}} +// In a hackish way, we disable permissions until now, so setup code works, but enable them for runtime so compile code works with permissions +try { + FS.ignorePermissions = false; +} catch(e){} + #if INVOKE_RUN #else Module['noInitialRun'] = true; |