Zulip Chat Archive
Stream: mathlib4
Topic: Bug in `fin_cases`?
Riccardo Brasca (Jul 21 2023 at 17:29):
Is this a bug in fin_cases
or I am missing something?
import Mathlib.Tactic
example (p : ℕ) (h2 : 2 < p) (h5 : p < 5) : p = 3 ∨ p = 4 := by
have hp : p ∈ Finset.Ioo 2 5 := (Finset.mem_Ioo).2 ⟨h2, h5⟩
fin_cases hp -- Hypothesis must be of type `x ∈ (A : List α)`, `x ∈ (A : Finset α)`, or `x ∈ (A : Multiset α)`
If I give hp : p ∈ Finset.Ioo 2 5
as an explicit assumption than fin_cases
works as expected.
Kyle Miller (Jul 21 2023 at 17:37):
In the code it looks like a missing instantiateMVars
. I'll check if that's right.
Riccardo Brasca (Jul 21 2023 at 17:45):
Thanks!
Kyle Miller (Jul 21 2023 at 18:05):
@Riccardo Brasca #6046
Riccardo Brasca (Jul 21 2023 at 18:16):
(I am not going to review it since my knowledge in meta code is essentially zero)
Kevin Buzzard (Jul 21 2023 at 18:37):
But you've done your job -- you found and minimised the issue :-)
Last updated: Dec 20 2023 at 11:08 UTC