Mercurial > urweb
comparison src/jscomp.sml @ 693:655bcc9b77e0
_Really_ implement embedded closure GC; extend Scriptcheck to figure out when client IDs must be assigned
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Sat, 04 Apr 2009 14:03:39 -0400 |
parents | 09df0c85f306 |
children | 7ea0df9e56b6 |
comparison
equal
deleted
inserted
replaced
692:09df0c85f306 | 693:655bcc9b77e0 |
---|---|
848 | EStrcat (e1, e2) => | 848 | EStrcat (e1, e2) => |
849 let | 849 let |
850 val (e1, st) = jsE inner (e1, st) | 850 val (e1, st) = jsE inner (e1, st) |
851 val (e2, st) = jsE inner (e2, st) | 851 val (e2, st) = jsE inner (e2, st) |
852 in | 852 in |
853 (strcat [str "(", e1, str "+", e2, str ")"], st) | 853 (strcat [str "cat(", e1, str ",", e2, str ")"], st) |
854 end | 854 end |
855 | 855 |
856 | EError (e, _) => | 856 | EError (e, _) => |
857 let | 857 let |
858 val (e, st) = jsE inner (e, st) | 858 val (e, st) = jsE inner (e, st) |
889 str ")"], st) | 889 str ")"], st) |
890 end | 890 end |
891 | 891 |
892 | EJavaScript (Source _, _, SOME _) => (e, st) | 892 | EJavaScript (Source _, _, SOME _) => (e, st) |
893 | EJavaScript (_, _, SOME e) => | 893 | EJavaScript (_, _, SOME e) => |
894 (strcat [str "function(){return ", | 894 (strcat [str "cs(function(){return ", |
895 e, | 895 e, |
896 str "}"], | 896 str "})"], |
897 st) | 897 st) |
898 | 898 |
899 | EClosure _ => unsupported "EClosure" | 899 | EClosure _ => unsupported "EClosure" |
900 | EQuery _ => unsupported "Query" | 900 | EQuery _ => unsupported "Query" |
901 | EDml _ => unsupported "DML" | 901 | EDml _ => unsupported "DML" |
903 | EUnurlify _ => unsupported "EUnurlify" | 903 | EUnurlify _ => unsupported "EUnurlify" |
904 | EJavaScript (_, e, _) => | 904 | EJavaScript (_, e, _) => |
905 let | 905 let |
906 val (e, st) = jsE inner (e, st) | 906 val (e, st) = jsE inner (e, st) |
907 in | 907 in |
908 (strcat [str "function(){return ", | 908 (strcat [str "cs(function(){return ", |
909 e, | 909 e, |
910 str "}"], | 910 str "})"], |
911 st) | 911 st) |
912 end | 912 end |
913 | 913 |
914 | ESignalReturn e => | 914 | ESignalReturn e => |
915 let | 915 let |