diff options
| author | Pierre-Marie Pédrot | 2020-11-15 00:17:21 +0100 |
|---|---|---|
| committer | Pierre-Marie Pédrot | 2020-11-15 00:17:21 +0100 |
| commit | ecea6eda26e18dfacff3793d6ceed5b63e46bb3e (patch) | |
| tree | df01feec359299fb3159d831d0c7735b8f280a74 /pretyping | |
| parent | 6b7d6be8eb0b8c12804a53475e33c1489e3bc61e (diff) | |
| parent | 89f5d2503d68dae235b9c2153d34f0def30ff626 (diff) | |
Merge PR #13356: Make the universe of primitive arrays irrelevant
Reviewed-by: ppedrot
Diffstat (limited to 'pretyping')
| -rw-r--r-- | pretyping/evarconv.ml | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/pretyping/evarconv.ml b/pretyping/evarconv.ml index 90af143a2d..ca16c52026 100644 --- a/pretyping/evarconv.ml +++ b/pretyping/evarconv.ml @@ -567,8 +567,13 @@ and evar_eqappr_x ?(rhs_is_already_stuck = false) flags env evd pbty let compare_heads evd = match EConstr.kind evd term, EConstr.kind evd term' with | Const (c, u), Const (c', u') when QConstant.equal env c c' -> - let u = EInstance.kind evd u and u' = EInstance.kind evd u' in - check_strict evd u u' + if Int.equal (Stack.args_size sk) 1 && Environ.is_array_type env c + then + let u = EInstance.kind evd u and u' = EInstance.kind evd u' in + compare_cumulative_instances evd [|Univ.Variance.Irrelevant|] u u' + else + let u = EInstance.kind evd u and u' = EInstance.kind evd u' in + check_strict evd u u' | Const _, Const _ -> UnifFailure (evd, NotSameHead) | Ind ((mi,i) as ind , u), Ind (ind', u') when Names.Ind.CanOrd.equal ind ind' -> if EInstance.is_empty u && EInstance.is_empty u' then Success evd |
