Mercurial > urweb
diff lib/top.urs @ 469:b393c2fc80f8
About to begin optimization of recursive transaction functions
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Thu, 06 Nov 2008 17:09:53 -0500 |
parents | dfc8c991abd0 |
children | 7cb418e9714f |
line wrap: on
line diff
--- a/lib/top.urs Thu Nov 06 15:52:13 2008 -0500 +++ b/lib/top.urs Thu Nov 06 17:09:53 2008 -0500 @@ -141,6 +141,14 @@ -> xml ctx [] []) -> transaction (xml ctx [] []) +val queryX' : tables ::: {{Type}} -> exps ::: {Type} -> ctx ::: {Unit} + -> sql_query tables exps + -> fn [tables ~ exps] => + ($(exps ++ fold (fn nm (fields :: {Type}) acc [[nm] ~ acc] => + [nm = $fields] ++ acc) [] tables) + -> transaction (xml ctx [] [])) + -> transaction (xml ctx [] []) + val oneOrNoRows : tables ::: {{Type}} -> exps ::: {Type} -> sql_query tables exps -> fn [tables ~ exps] =>