Skip to content

linarith not ignoring irrelevant (in)equalities #2610

Closed

Description

@mo271

see https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/linarith.20and.20ENNReal and the mwe of @eric-wieser there:

import Mathlib.Tactic.Linarith

example : 0 ≤ 1 := by linarith -- ok

example (s : Set ℕ) (h : s = ∅) : 0 ≤ 1 :=
by linarith
/-
failed to synthesize
  AddGroup (Set ℕ)
-/

Seems like linarith should ignore (in)equalities in the context it doesn't get.

Activity

  1. added
    bug
    on Mar 3, 2023
  2. mo271 commented on Mar 3, 2023

    @mo271
    CollaboratorAuthor

    I see, you used the same workaround: clear the interfering lemmas before invoking linarith.

  3. added a commit that references this issue on Mar 3, 2023
    7125ba9
  4. added
    t-meta
    on Mar 21, 2023
  5. added a commit that references this issue on Apr 20, 2023
    32cb47a
  6. added a commit that references this issue on May 10, 2023
    44cd35f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugt-meta

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions