Commit 9921ef86 authored by Francois Bobot's avatar Francois Bobot
Browse files

ne fait aucune transformation si aucune n'a été demandé

parent b48a56e5
...@@ -28,7 +28,6 @@ let loadpath = ref [] ...@@ -28,7 +28,6 @@ let loadpath = ref []
let print_stdout = ref false let print_stdout = ref false
let simplify_recursive = ref false let simplify_recursive = ref false
let inlining = ref false let inlining = ref false
let transform = ref false
let alt_ergo = ref false let alt_ergo = ref false
let () = let () =
...@@ -41,14 +40,13 @@ let () = ...@@ -41,14 +40,13 @@ let () =
"--print-stdout", Arg.Set print_stdout, "print the results to stdout"; "--print-stdout", Arg.Set print_stdout, "print the results to stdout";
"--simplify-recursive", Arg.Set simplify_recursive, "simplify recursive definition"; "--simplify-recursive", Arg.Set simplify_recursive, "simplify recursive definition";
"--inline", Arg.Set inlining, "inline the definition not recursive"; "--inline", Arg.Set inlining, "inline the definition not recursive";
"--transform", Arg.Set transform, "transform the goal (--inline,and --simplify-recursive set it) ";
"--alt-ergo", Arg.Set alt_ergo, "output for Alt-Ergo on stdout"; "--alt-ergo", Arg.Set alt_ergo, "output for Alt-Ergo on stdout";
] ]
(fun f -> files := f :: !files) (fun f -> files := f :: !files)
"usage: why [options] files..." "usage: why [options] files..."
let in_emacs = Sys.getenv "TERM" = "dumb" let in_emacs = Sys.getenv "TERM" = "dumb"
let transform = !transform || !simplify_recursive || !inlining let transform = !simplify_recursive || !inlining
let rec report fmt = function let rec report fmt = function
| Lexer.Error e -> | Lexer.Error e ->
...@@ -90,7 +88,7 @@ let transform l = ...@@ -90,7 +88,7 @@ let transform l =
| [] -> () | [] -> ()
end end
| [] -> () | [] -> ()
else else if transform then
let l = List.map (fun t -> t,Transform.apply Flatten.t t.th_ctxt) let l = List.map (fun t -> t,Transform.apply Flatten.t t.th_ctxt)
l in l in
let l = if !simplify_recursive let l = if !simplify_recursive
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment