diff options
Diffstat (limited to 'src/iflow.sml')
-rw-r--r-- | src/iflow.sml | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/iflow.sml b/src/iflow.sml index f68d8f72..8bde7ea3 100644 --- a/src/iflow.sml +++ b/src/iflow.sml @@ -1263,7 +1263,7 @@ fun doQuery (arg : 'a doQuery) (e as (_, loc)) = val new = ref NONE val old = ref NONE - val rvs = map (fn (tab, v) => + val rvs = map (fn Table (tab, v) => let val nv = #NextVar arg () in @@ -1272,7 +1272,8 @@ fun doQuery (arg : 'a doQuery) (e as (_, loc)) = | "Old" => old := SOME (tab, nv) | _ => (); (v, nv) - end) (#From r) + end + | _ => raise Fail "Iflow: not ready for joins or nesteds") (#From r) fun rvOf v = case List.find (fn (v', _) => v' = v) rvs of @@ -1282,7 +1283,8 @@ fun doQuery (arg : 'a doQuery) (e as (_, loc)) = val expIn = expIn (#NextVar arg) (#Env arg) rvOf val saved = #Save arg () - fun addFrom () = app (fn (t, v) => #Add arg (AReln (Sql t, [rvOf v]))) (#From r) + fun addFrom () = app (fn Table (t, v) => #Add arg (AReln (Sql t, [rvOf v])) + | _ => raise Fail "Iflow: not ready for joins or nesteds") (#From r) fun usedFields e = case e of |