aboutsummaryrefslogtreecommitdiff
path: root/plugins/ssr
diff options
context:
space:
mode:
authorEmilio Jesus Gallego Arias2019-03-03 16:49:30 +0100
committerEmilio Jesus Gallego Arias2019-07-07 00:57:28 +0200
commit07abf9818a6b47bb2c2bd0a8201da9743a0c10b6 (patch)
tree0325550fcf395bad3f4951259202f97db182fbaf /plugins/ssr
parentae7fc8bc74289bd8a1eca48c8ca8ecf923888285 (diff)
[error] Remove special error printing pre-processing
We remove the special error printing pre-processing in favor of just calling the standard printers. Error printing has been a bit complex for a while due to an incomplete migration to a new printing scheme based on registering exception printers; this PR should alleviate that by completing the registration approach. After this cleanup, it should not be ever necessary for normal functions to worry a lot about catching errors and re-raising them, unless they have some very special needs. This change also allows to consolidate the `explainErr` and `himsg` modules into one, removing the need to export the error printing functions. Ideally we would make the contents of `himsg` more localized, but this can be done in a gradual way.
Diffstat (limited to 'plugins/ssr')
-rw-r--r--plugins/ssr/ssrvernac.mlg9
1 files changed, 4 insertions, 5 deletions
diff --git a/plugins/ssr/ssrvernac.mlg b/plugins/ssr/ssrvernac.mlg
index 279e7ce1a6..0adabb0673 100644
--- a/plugins/ssr/ssrvernac.mlg
+++ b/plugins/ssr/ssrvernac.mlg
@@ -412,11 +412,10 @@ let interp_search_arg arg =
if is_ident_part s then Search.GlobSearchString s else
interp_search_notation ~loc s key
| RGlobSearchSubPattern p ->
- try
- let env = Global.env () in
- let _, p = Constrintern.intern_constr_pattern env (Evd.from_env env) p in
- Search.GlobSearchSubPattern p
- with e -> let e = CErrors.push e in iraise (ExplainErr.process_vernac_interp_error e)) arg in
+ let env = Global.env () in
+ let _, p = Constrintern.intern_constr_pattern env (Evd.from_env env) p in
+ Search.GlobSearchSubPattern p) arg
+ in
let hpat, a1 = match arg with
| (_, Search.GlobSearchSubPattern (Pattern.PMeta _)) :: a' -> all_true, a'
| (true, Search.GlobSearchSubPattern p) :: a' ->