aboutsummaryrefslogtreecommitdiff
path: root/src/shell.js
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2013-11-18 17:01:01 -0800
committerAlon Zakai <alonzakai@gmail.com>2013-11-18 17:01:01 -0800
commit28b3a25d98de7073da8736426c01e3f0c7d12cb2 (patch)
treea38a50d45e050c9cf17950bd375030c24a90c5e0 /src/shell.js
parentd773f2f3cd4f0a35d3853859a8cd81b8d76c277b (diff)
better fix for closure issue in asm2f.test_exceptions; clear out the spidermonkey shell gc() function
Diffstat (limited to 'src/shell.js')
-rw-r--r--src/shell.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/shell.js b/src/shell.js
index b68e16d9..b41fbb51 100644
--- a/src/shell.js
+++ b/src/shell.js
@@ -91,6 +91,8 @@ else if (ENVIRONMENT_IS_SHELL) {
}
this['{{{ EXPORT_NAME }}}'] = Module;
+
+ eval("if (typeof gc === 'function' && gc.toString().indexOf('[native code]') > 0) var gc = undefined"); // wipe out the SpiderMonkey shell 'gc' function, which can confuse closure (uses it as a minified name, and it is then initted to a non-falsey value unexpectedly)
}
else if (ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER) {
Module['read'] = function read(url) {