summaryrefslogtreecommitdiff
path: root/src/compiler.sml
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler.sml')
-rw-r--r--src/compiler.sml10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/compiler.sml b/src/compiler.sml
index 256162ce..baf8ddac 100644
--- a/src/compiler.sml
+++ b/src/compiler.sml
@@ -71,10 +71,20 @@ type ('src, 'dst) transform = {
time : 'src * pmap -> 'dst option * pmap
}
+val debug = ref false
+
fun transform (ph : ('src, 'dst) phase) name = {
func = fn input => let
+ val () = if !debug then
+ print ("Starting " ^ name ^ "....\n")
+ else
+ ()
val v = #func ph input
in
+ if !debug then
+ print ("Finished " ^ name ^ ".\n")
+ else
+ ();
if ErrorMsg.anyErrors () then
NONE
else