summaryrefslogtreecommitdiff
path: root/src/compiler.sml
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adamc@hcoop.net>2010-05-06 13:57:01 -0400
committerGravatar Adam Chlipala <adamc@hcoop.net>2010-05-06 13:57:01 -0400
commit11de01a71c637cddaf6a7eb1c4bbe31a8162a6d5 (patch)
tree0931e395c9448d6b3b9f4120a3b4c47c9dad9846 /src/compiler.sml
parent68dc3c23e37d57921f0c5110d7121952818468ff (diff)
parent55edf40b3a3a41eb99b55261e9191ab8772be83a (diff)
Merge
Diffstat (limited to 'src/compiler.sml')
-rw-r--r--src/compiler.sml10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/compiler.sml b/src/compiler.sml
index a2fcd346..def0e6c3 100644
--- a/src/compiler.sml
+++ b/src/compiler.sml
@@ -75,6 +75,7 @@ type ('src, 'dst) transform = {
}
val debug = ref false
+val doIflow = ref false
fun transform (ph : ('src, 'dst) phase) name = {
func = fn input => let
@@ -1071,12 +1072,19 @@ val toMono_shake = transform mono_shake "mono_shake1" o toMono_reduce
val toMono_opt2 = transform mono_opt "mono_opt2" o toMono_shake
+val iflow = {
+ func = (fn file => (if !doIflow then Iflow.check file else (); file)),
+ print = MonoPrint.p_file MonoEnv.empty
+}
+
+val toIflow = transform iflow "iflow" o toMono_opt2
+
val jscomp = {
func = JsComp.process,
print = MonoPrint.p_file MonoEnv.empty
}
-val toJscomp = transform jscomp "jscomp" o toMono_opt2
+val toJscomp = transform jscomp "jscomp" o toIflow
val toMono_opt3 = transform mono_opt "mono_opt3" o toJscomp