diff options
author | Adam Chlipala <adamc@hcoop.net> | 2008-09-02 17:31:45 -0400 |
---|---|---|
committer | Adam Chlipala <adamc@hcoop.net> | 2008-09-02 17:31:45 -0400 |
commit | ab29ac3337d2be88ae3288652e999873be1dcf14 (patch) | |
tree | d3816565ec3c8518bb73979bd5957e8d324375f9 /src/compiler.sml | |
parent | 5885d66bebeece6ba2f7b6a1b11f719086423114 (diff) |
Compiling a parametrized query the inefficient way
Diffstat (limited to 'src/compiler.sml')
-rw-r--r-- | src/compiler.sml | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/src/compiler.sml b/src/compiler.sml index f9fe0da8..263aaf9a 100644 --- a/src/compiler.sml +++ b/src/compiler.sml @@ -93,15 +93,17 @@ fun op o (tr2 : ('b, 'c) transform, tr1 : ('a, 'b) transform) = { end } -fun run (tr : ('src, 'dst) transform) = #func tr +fun run (tr : ('src, 'dst) transform) x = (ErrorMsg.resetErrors (); + #func tr x) fun runPrint (tr : ('src, 'dst) transform) input = - case #func tr input of - NONE => print "Failure\n" - | SOME v => - (print "Success\n"; - Print.print (#print tr v); - print "\n") + (ErrorMsg.resetErrors (); + case #func tr input of + NONE => print "Failure\n" + | SOME v => + (print "Success\n"; + Print.print (#print tr v); + print "\n")) fun time (tr : ('src, 'dst) transform) input = let |