diff options
| author | Georges Gonthier | 2019-03-18 12:49:18 +0100 |
|---|---|---|
| committer | Georges Gonthier | 2019-03-18 12:49:18 +0100 |
| commit | 7f25b156d2e33ec767732175f7030cd103e9b695 (patch) | |
| tree | 94eddb7e9bca379c3ec50e73c91301da459a0d18 /mathcomp | |
| parent | e6622f6910759ed8bf07ce94827da778d397d228 (diff) | |
remove dependency on hidden case branch types
Anticipating coq/coq#9170, remove numeric occurrence selector affected
by the (invisible) presence of explicit types for variables bound in
`match` branch patterns. The proof could be further simplified if this
change is implemented.
Diffstat (limited to 'mathcomp')
| -rw-r--r-- | mathcomp/ssreflect/fintype.v | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/mathcomp/ssreflect/fintype.v b/mathcomp/ssreflect/fintype.v index 2544ab6..93810ca 100644 --- a/mathcomp/ssreflect/fintype.v +++ b/mathcomp/ssreflect/fintype.v @@ -1950,8 +1950,12 @@ Variant split_spec m n (i : 'I_(m + n)) : 'I_m + 'I_n -> bool -> Type := Lemma splitP m n (i : 'I_(m + n)) : split_spec i (split i) (i < m). Proof. -rewrite /split {-3}/leq. -by case: (@ltnP i m) => cmp_i_m //=; constructor; rewrite ?subnKC. +(* We need to prevent the case on ltnP from rewriting the hidden constructor *) +(* argument types of the match branches exposed by unfolding split. If the *) +(* match representation is changed to omit these then this proof could reduce *) +(* to by rewrite /split; case: ltnP; [left | right. rewrite subnKC]. *) +set lt_i_m := i < m; rewrite /split. +by case: {-}_ lt_i_m / ltnP; [left | right; rewrite subnKC]. Qed. Definition unsplit {m n} (jk : 'I_m + 'I_n) := |
