From abe12b0631e69288e3df631e1898e58007cb292e Mon Sep 17 00:00:00 2001 From: Leonardo de Moura Date: Mon, 30 Jun 2014 18:04:18 -0700 Subject: [PATCH] fix(shell/lean): only save .olean file if there are no errors Signed-off-by: Leonardo de Moura --- src/shell/lean.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shell/lean.cpp b/src/shell/lean.cpp index 6feaa559b..55c6eb8b8 100644 --- a/src/shell/lean.cpp +++ b/src/shell/lean.cpp @@ -235,7 +235,7 @@ int main(int argc, char ** argv) { lean::interactive in(env, ios, num_threads); in(std::cin, "[stdin]"); } - if (export_objects) { + if (export_objects && ok) { std::ofstream out(output, std::ofstream::binary); export_module(out, env); }