avoid extra subprocess -- potentially more robust on Cygwin;
authorwenzelm
Fri, 24 May 2019 20:16:35 +0200
changeset 70288 2e101846ad8f
parent 70287 b0fd8167bb9b
child 70289 85de4fdec61b
avoid extra subprocess -- potentially more robust on Cygwin;
src/HOL/Tools/SMT/smt_solver.ML
--- a/src/HOL/Tools/SMT/smt_solver.ML	Fri May 24 20:08:52 2019 +0200
+++ b/src/HOL/Tools/SMT/smt_solver.ML	Fri May 24 20:16:35 2019 +0200
@@ -49,9 +49,8 @@
 local
 
 fun make_command command options problem_path proof_path =
-  "(exec 2>&1;" :: map Bash.string (command () @ options) @
-  [File.bash_path problem_path, ")", ">", File.bash_path proof_path]
-  |> space_implode " "
+  Bash.strings (command () @ options) ^ " " ^ File.bash_path problem_path ^
+    " > " ^ File.bash_path proof_path ^ " 2>&1"
 
 fun with_trace ctxt msg f x =
   let val _ = SMT_Config.trace_msg ctxt (fn () => msg) ()