Mercurial > urweb
comparison src/iflow.sml @ 2255:8428c534913a
Use new refactored urlification in Sqlcache.
author | Ziv Scully <ziv@mit.edu> |
---|---|
date | Mon, 21 Sep 2015 16:45:59 -0400 |
parents | e843a04499d4 |
children | 6fb9232ade99 |
comparison
equal
deleted
inserted
replaced
2254:44ae2254f8fb | 2255:8428c534913a |
---|---|
1868 val namer = MonoUtil.File.map {typ = fn t => t, | 1868 val namer = MonoUtil.File.map {typ = fn t => t, |
1869 exp = fn e => | 1869 exp = fn e => |
1870 case e of | 1870 case e of |
1871 EDml (e, fm) => | 1871 EDml (e, fm) => |
1872 nameSubexps (fn (_, e') => (EDml (e', fm), #2 e)) e | 1872 nameSubexps (fn (_, e') => (EDml (e', fm), #2 e)) e |
1873 | EQuery {exps, tables, state, query, body, initial, sqlcacheInfo} => | 1873 | EQuery {exps, tables, state, query, body, initial} => |
1874 nameSubexps (fn (liftBy, e') => | 1874 nameSubexps (fn (liftBy, e') => |
1875 (EQuery {exps = exps, | 1875 (EQuery {exps = exps, |
1876 tables = tables, | 1876 tables = tables, |
1877 state = state, | 1877 state = state, |
1878 query = e', | 1878 query = e', |
1879 body = mliftExpInExp liftBy 2 body, | 1879 body = mliftExpInExp liftBy 2 body, |
1880 initial = mliftExpInExp liftBy 0 initial, | 1880 initial = mliftExpInExp liftBy 0 initial}, |
1881 sqlcacheInfo = sqlcacheInfo}, | |
1882 #2 query)) query | 1881 #2 query)) query |
1883 | _ => e, | 1882 | _ => e, |
1884 decl = fn d => d} | 1883 decl = fn d => d} |
1885 | 1884 |
1886 fun check (file : file) = | 1885 fun check (file : file) = |
2069 | ERedirect (e1, t) => (ERedirect (doExp env e1, t), loc) | 2068 | ERedirect (e1, t) => (ERedirect (doExp env e1, t), loc) |
2070 | EWrite e1 => (EWrite (doExp env e1), loc) | 2069 | EWrite e1 => (EWrite (doExp env e1), loc) |
2071 | ESeq (e1, e2) => (ESeq (doExp env e1, doExp env e2), loc) | 2070 | ESeq (e1, e2) => (ESeq (doExp env e1, doExp env e2), loc) |
2072 | ELet (x, t, e1, e2) => (ELet (x, t, doExp env e1, doExp (Unknown :: env) e2), loc) | 2071 | ELet (x, t, e1, e2) => (ELet (x, t, doExp env e1, doExp (Unknown :: env) e2), loc) |
2073 | EClosure (n, es) => (EClosure (n, map (doExp env) es), loc) | 2072 | EClosure (n, es) => (EClosure (n, map (doExp env) es), loc) |
2074 | EQuery {exps, tables, state, query, body, initial, sqlcacheInfo} => | 2073 | EQuery {exps, tables, state, query, body, initial} => |
2075 (EQuery {exps = exps, tables = tables, state = state, | 2074 (EQuery {exps = exps, tables = tables, state = state, |
2076 query = doExp env query, | 2075 query = doExp env query, |
2077 body = doExp (Unknown :: Unknown :: env) body, | 2076 body = doExp (Unknown :: Unknown :: env) body, |
2078 initial = doExp env initial, | 2077 initial = doExp env initial}, loc) |
2079 sqlcacheInfo = sqlcacheInfo}, loc) | |
2080 | EDml (e1, mode) => | 2078 | EDml (e1, mode) => |
2081 (case parse dml e1 of | 2079 (case parse dml e1 of |
2082 NONE => () | 2080 NONE => () |
2083 | SOME c => | 2081 | SOME c => |
2084 case c of | 2082 case c of |