diff options
| author | Maxime Dénès | 2016-10-25 08:39:53 +0200 |
|---|---|---|
| committer | Maxime Dénès | 2016-10-25 08:39:53 +0200 |
| commit | b00f7cdd1905e7d7c1f0241284f0808f8e1d2c45 (patch) | |
| tree | 24994922773f96baa2e644bbcc25ab01f686d41a /pretyping/evd.ml | |
| parent | b63a5cfa919fc0ebe664bbfb3add0fce387b1491 (diff) | |
| parent | 52a37da6b9e5d4e2024e31710df4e39cbd372865 (diff) | |
Merge remote-tracking branch 'github/pr/333' into v8.5
Was PR#233: Fix a bug in error printing of unif constraints
Diffstat (limited to 'pretyping/evd.ml')
| -rw-r--r-- | pretyping/evd.ml | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/pretyping/evd.ml b/pretyping/evd.ml index 0bc688aacf..2f4b8fc12f 100644 --- a/pretyping/evd.ml +++ b/pretyping/evd.ml @@ -840,6 +840,7 @@ let set_universe_context evd uctx' = { evd with universes = uctx' } let add_conv_pb ?(tail=false) pb d = + (** MS: we have duplicates here, why? *) if tail then {d with conv_pbs = d.conv_pbs @ [pb]} else {d with conv_pbs = pb::d.conv_pbs} @@ -1888,6 +1889,16 @@ let print_env_short env = let pr_evar_constraints pbs = let pr_evconstr (pbty, env, t1, t2) = + let env = + (** We currently allow evar instances to refer to anonymous de + Bruijn indices, so we protect the error printing code in this + case by giving names to every de Bruijn variable in the + rel_context of the conversion problem. MS: we should rather + stop depending on anonymous variables, they can be used to + indicate independency. Also, this depends on a strategy for + naming/renaming. *) + Namegen.make_all_name_different env + in print_env_short env ++ spc () ++ str "|-" ++ spc () ++ print_constr_env env t1 ++ spc () ++ str (match pbty with |
