comparison src/monoize.sml @ 753:d484df4e841a

Preparing to allow views in SELECT FROM clauses
author Adam Chlipala <adamc@hcoop.net>
date Tue, 28 Apr 2009 14:02:23 -0400
parents f95d652086cd
children 8688e01ae469
comparison
equal deleted inserted replaced
752:bc5cfd6cb30f 753:d484df4e841a
182 (L'.TFfi ("Basis", "string"), loc) 182 (L'.TFfi ("Basis", "string"), loc)
183 | L.CFfi ("Basis", "sql_limit") => 183 | L.CFfi ("Basis", "sql_limit") =>
184 (L'.TFfi ("Basis", "string"), loc) 184 (L'.TFfi ("Basis", "string"), loc)
185 | L.CFfi ("Basis", "sql_offset") => 185 | L.CFfi ("Basis", "sql_offset") =>
186 (L'.TFfi ("Basis", "string"), loc) 186 (L'.TFfi ("Basis", "string"), loc)
187 | L.CApp ((L.CApp ((L.CFfi ("Basis", "fieldsOf"), _), _), _), _) =>
188 (L'.TRecord [], loc)
187 189
188 | L.CApp ((L.CFfi ("Basis", "sql_injectable_prim"), _), t) => 190 | L.CApp ((L.CFfi ("Basis", "sql_injectable_prim"), _), t) =>
189 (L'.TFun (mt env dtmap t, (L'.TFfi ("Basis", "string"), loc)), loc) 191 (L'.TFun (mt env dtmap t, (L'.TFfi ("Basis", "string"), loc)), loc)
190 | L.CApp ((L.CFfi ("Basis", "sql_injectable"), _), t) => 192 | L.CApp ((L.CFfi ("Basis", "sql_injectable"), _), t) =>
191 (L'.TFun (mt env dtmap t, (L'.TFfi ("Basis", "string"), loc)), loc) 193 (L'.TFun (mt env dtmap t, (L'.TFfi ("Basis", "string"), loc)), loc)
1723 | L.ECApp ((L.EFfi ("Basis", "sql_subset"), _), _) => 1725 | L.ECApp ((L.EFfi ("Basis", "sql_subset"), _), _) =>
1724 ((L'.ERecord [], loc), fm) 1726 ((L'.ERecord [], loc), fm)
1725 | L.ECApp ((L.EFfi ("Basis", "sql_subset_all"), _), _) => 1727 | L.ECApp ((L.EFfi ("Basis", "sql_subset_all"), _), _) =>
1726 ((L'.ERecord [], loc), fm) 1728 ((L'.ERecord [], loc), fm)
1727 1729
1728 | L.ECApp ((L.ECApp ((L.ECApp ((L.EFfi ("Basis", "sql_from_table"), _), _), _), _), _), 1730 | L.ECApp ((L.ECApp ((L.EFfi ("Basis", "fieldsOf_table"), _), _), _), _) =>
1729 (L.CName name, _)) => 1731 ((L'.ERecord [], loc), fm)
1732 | L.ECApp ((L.EFfi ("Basis", "fieldsOf_view"), _), _) =>
1733 ((L'.ERecord [], loc), fm)
1734
1735 | L.ECApp ((L.EApp ((L.ECApp ((L.ECApp ((L.EFfi ("Basis", "sql_from_table"), _), _), _), _), _), _), _),
1736 (L.CName name, _)) =>
1730 let 1737 let
1731 val s = (L'.TFfi ("Basis", "string"), loc) 1738 val s = (L'.TFfi ("Basis", "string"), loc)
1732 in 1739 in
1733 ((L'.EAbs ("tab", s, s, 1740 ((L'.EAbs ("tab", s, s,
1734 strcat [(L'.ERel 0, loc), 1741 strcat [(L'.ERel 0, loc),