diff options
author | 2013-03-13 00:00:59 +0000 | |
---|---|---|
committer | 2013-03-13 00:00:59 +0000 | |
commit | 033fed4d6788be791bb1c980f3cddc10827d6318 (patch) | |
tree | 42184b7d27f439e74aee474c34afd623b9d91087 /plugins/omega | |
parent | 8d70a84682ded179c461e633c7865486c63e55db (diff) |
Restrict (try...with...) to avoid catching critical exn (part 15)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@16292 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'plugins/omega')
-rw-r--r-- | plugins/omega/coq_omega.ml | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/omega/coq_omega.ml b/plugins/omega/coq_omega.ml index c4961654d..f98aba0a8 100644 --- a/plugins/omega/coq_omega.ml +++ b/plugins/omega/coq_omega.ml @@ -874,7 +874,7 @@ let rec transform p t = try let v,th,_ = find_constr t' in [clever_rewrite_base p (mkVar v) (mkVar th)], Oatom v - with _ -> + with e when Errors.noncritical e -> let v = new_identifier_var () and th = new_identifier () in hide_constr t' v th isnat; @@ -913,7 +913,8 @@ let rec transform p t = | _ -> default false t end | Kapp((Zpos|Zneg|Z0),_) -> - (try ([],Oz(recognize_number t)) with _ -> default false t) + (try ([],Oz(recognize_number t)) + with e when Errors.noncritical e -> default false t) | Kvar s -> [],Oatom s | Kapp(Zopp,[t]) -> let tac,t' = transform (P_APP 1 :: p) t in |