Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding certain rules causes kernel error in later theorem #186

Open
hgoldstein95 opened this issue Dec 27, 2024 · 0 comments
Open

Adding certain rules causes kernel error in later theorem #186

hgoldstein95 opened this issue Dec 27, 2024 · 0 comments

Comments

@hgoldstein95
Copy link

I'm not 100% sure this is an Aesop problem, it could be a core Lean issue, but I can't get the issue to happen without Aesop so I'm starting here.

Here's an example of a couple of very simple theorems:

import Aesop

theorem foo
    {T : Prop → Prop}
    (h : ∀ v, T (v = 2)) :
    ∀ v, T (2 = v) := by
  aesop? (add unsafe (by simp_all [eq_comm]))

theorem bar (h : Q ∧ P) : P ∧ Q := by
  simp_all [and_comm]

Aesop easily solves foo, suggesting the proof intro v; (simp_all [eq_comm]) as expected, but then bar fails with the message "(kernel) constant has already been declared 'Module._auxLemma.1'".

If I replace the call to aesop with the suggested proof, everything compiles correctly.

Any idea what's going on?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant