diff lib/js/urweb.js @ 1262:003df929ee08

Switch to strings and eval for thunkifying JavaScripted functions
author Adam Chlipala <adamc@hcoop.net>
date Sat, 22 May 2010 16:29:54 -0400
parents 25ebd8c4fafb
children 6791454653c5
line wrap: on
line diff
--- a/lib/js/urweb.js	Sat May 22 14:14:02 2010 -0400
+++ b/lib/js/urweb.js	Sat May 22 16:29:54 2010 -0400
@@ -1078,7 +1078,7 @@
             var idx = e.n;
             e = urfuncs[idx];
             if (e.c == "t")
-                e = urfuncs[idx] = e.f();
+                e = urfuncs[idx] = eval("(" + e.f + ")");
             break;
         case "s":
             stack = cons({c: "s"}, stack);