diff options
author | Adam Chlipala <adam@chlipala.net> | 2011-08-21 13:41:57 -0400 |
---|---|---|
committer | Adam Chlipala <adam@chlipala.net> | 2011-08-21 13:41:57 -0400 |
commit | 9239ce8a90f9c983881216cfece4161a831216d4 (patch) | |
tree | 048f39efd512e604237cc836a8b2ee536ac75c57 /tests/rpcList2.ur | |
parent | 1e022eb78e7ca3fd15634e3845756b9c14209cf3 (diff) |
Fix another list unurlification segfault bug; List.foldlMi
Diffstat (limited to 'tests/rpcList2.ur')
-rw-r--r-- | tests/rpcList2.ur | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/rpcList2.ur b/tests/rpcList2.ur index c0739b84..e3ebb456 100644 --- a/tests/rpcList2.ur +++ b/tests/rpcList2.ur @@ -1,7 +1,13 @@ -fun rpcFunc l : transaction {} = return () +fun showList l = case l of + [] => "[]" + | h :: t => strcat (strcat (show h) " :: ") (showList t) + +fun rpcFunc l : transaction string = + case l of h :: _ => return (showList h) | [] => return "[]" fun main () : transaction page = return <xml><body> <button onclick={ - rpc (rpcFunc (("" :: []) :: [])) + s <- rpc (rpcFunc (("foo" :: []) :: [])); + alert s }/> </body></xml> |