aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Pierre-Marie Pédrot <pierre-marie.pedrot@inria.fr>2017-02-01 10:36:24 +0100
committerGravatar Pierre-Marie Pédrot <pierre-marie.pedrot@inria.fr>2017-02-01 10:48:25 +0100
commit568b38e1d599f8bac5adf140f5a114f2871bc436 (patch)
treef033e92941edde3b4287213c19cb7cd5a0c47f45
parenta54dccb53fa8d6c12745b5f7b2c3c993a915b5bd (diff)
parentf5923c2174fbb419397f127af31ab1cd0b223e0a (diff)
Merge branch 'v8.5' into v8.6
-rw-r--r--kernel/safe_typing.ml5
-rw-r--r--ltac/tacinterp.ml2
-rw-r--r--test-suite/bugs/closed/5331.v11
3 files changed, 16 insertions, 2 deletions
diff --git a/kernel/safe_typing.ml b/kernel/safe_typing.ml
index 95d9c75d3..bc1cb63d8 100644
--- a/kernel/safe_typing.ml
+++ b/kernel/safe_typing.ml
@@ -794,7 +794,10 @@ type compiled_library = {
type native_library = Nativecode.global list
let get_library_native_symbols senv dir =
- DPMap.find dir senv.native_symbols
+ try DPMap.find dir senv.native_symbols
+ with Not_found -> CErrors.errorlabstrm "get_library_native_symbols"
+ Pp.((str "Linker error in the native compiler. Are you using Require inside a nested Module declaration?") ++ fnl () ++
+ (str "This use case is not supported, but disabling the native compiler may help."))
(** FIXME: MS: remove?*)
let current_modpath senv = senv.modpath
diff --git a/ltac/tacinterp.ml b/ltac/tacinterp.ml
index 20dbc2be4..aa45f1ccf 100644
--- a/ltac/tacinterp.ml
+++ b/ltac/tacinterp.ml
@@ -957,7 +957,7 @@ let interp_or_and_intro_pattern_option ist env sigma = function
(match coerce_to_intro_pattern env (Id.Map.find id ist.lfun) with
| IntroAction (IntroOrAndPattern l) -> sigma, Some (loc,l)
| _ ->
- raise (CannotCoerceTo "a disjunctive/conjunctive introduction pattern"))
+ user_err_loc (loc,"", str "Cannot coerce to a disjunctive/conjunctive pattern."))
| Some (ArgArg (loc,l)) ->
let sigma,l = interp_or_and_intro_pattern ist env sigma l in
sigma, Some (loc,l)
diff --git a/test-suite/bugs/closed/5331.v b/test-suite/bugs/closed/5331.v
new file mode 100644
index 000000000..28743736d
--- /dev/null
+++ b/test-suite/bugs/closed/5331.v
@@ -0,0 +1,11 @@
+(* Checking no anomaly on some unexpected intropattern *)
+
+Ltac ih H := induction H as H.
+Ltac ih' H H' := induction H as H'.
+
+Goal True -> True.
+Fail intro H; ih H.
+intro H; ih' H ipattern:([]).
+exact I.
+Qed.
+