aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/compiler.sml
diff options
context:
space:
mode:
authorGravatar Ziv Scully <ziv@mit.edu>2014-03-08 05:06:22 -0500
committerGravatar Ziv Scully <ziv@mit.edu>2014-03-08 05:06:22 -0500
commit0e1252d5a6330570df698df924a0554b688042e8 (patch)
tree1346f6d8df030f4afa2ac573e254c63840244f77 /src/compiler.sml
parent2e3db71b6717f477ac24c4baa4fba1885cc55dad (diff)
Identifies tables read or touched by queries.
Diffstat (limited to 'src/compiler.sml')
-rw-r--r--src/compiler.sml19
1 files changed, 13 insertions, 6 deletions
diff --git a/src/compiler.sml b/src/compiler.sml
index cc4e33c5..36a1b03f 100644
--- a/src/compiler.sml
+++ b/src/compiler.sml
@@ -16,7 +16,7 @@
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
- * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
@@ -25,7 +25,7 @@
* POSSIBILITY OF SUCH DAMAGE.
*)
-structure Compiler :> COMPILER = struct
+structure Compiler :> COMPILER = struct
structure UrwebLrVals = UrwebLrValsFn(structure Token = LrParser.Token)
structure Lex = UrwebLexFn(structure Tokens = UrwebLrVals.Tokens)
@@ -268,7 +268,7 @@ val parseUr = {
| _ => absyn
end
handle LrParser.ParseError => [],
- print = SourcePrint.p_file}
+ print = SourcePrint.p_file}
fun p_job ({prefix, database, exe, sql, sources, debug, profile,
timeout, ffi, link, headers, scripts,
@@ -1090,7 +1090,7 @@ val parse = {
ErrorMsg.error ("Rooted module " ^ full ^ " has multiple versions.")
else
();
-
+
makeD true "" pieces
before ignore (foldl (fn (new, path) =>
let
@@ -1438,12 +1438,19 @@ val sigcheck = {
val toSigcheck = transform sigcheck "sigcheck" o toSidecheck
+val sqlcache = {
+ func = (fn file => (Sql.go file; file)),
+ print = MonoPrint.p_file MonoEnv.empty
+}
+
+val toSqlcache = transform sqlcache "sqlcache" o toSigcheck
+
val cjrize = {
func = Cjrize.cjrize,
print = CjrPrint.p_file CjrEnv.empty
}
-val toCjrize = transform cjrize "cjrize" o toSigcheck
+val toCjrize = transform cjrize "cjrize" o toSqlcache
val prepare = {
func = Prepare.prepare,
@@ -1596,7 +1603,7 @@ fun compile job =
compileC {cname = cname, oname = oname, ename = ename, libs = libs,
profile = #profile job, debug = #debug job, linker = #linker job, link = #link job}
-
+
before cleanup ())
end
handle ex => (((cleanup ()) handle _ => ()); raise ex)