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
[Merged by Bors] - fix(tactic/core): Make the classical
tactic behave like open_locale classical
#14122
Conversation
Note: if this works, we probably want to mimic |
Alternatively, we might want to just remove those lines from the |
Oh, actually |
Presumably it is to deal with performance issues causes by those instances. But the de-instantiated instances should of course be removed. |
This looks great! bors merge |
…e classical` (#14122) This renames the existing `classical` tactic to `classical!`, and adds a new `classical` tactic that is equivalent to `open_locale classical`. Comparing the effects of these: ```lean import tactic.interactive import tactic.localized -- this uses the noncomputable instance noncomputable def foo : decidable_eq ℕ := λ m n, begin classical!, apply_instance, end def bar : decidable_eq ℕ := λ m n, begin classical, apply_instance, end section open_locale classical def baz : decidable_eq ℕ := λ m n, by apply_instance end example : baz = bar := rfl ``` In a few places `classical` was actually just being used as a `resetI`. Only a very small number of uses of `classical` actually needed the more aggressive `classical!` (there are roughtly 500 uses in total); while a number of `congr`s can be eliminated with this change.
Pull request successfully merged into master. Build succeeded: |
classical
tactic behave like open_locale classical
classical
tactic behave like open_locale classical
This renames the existing
classical
tactic toclassical!
, and adds a newclassical
tactic that is equivalent toopen_locale classical
.Comparing the effects of these:
In a few places
classical
was actually just being used as aresetI
. Only a very small number of uses ofclassical
actually needed the more aggressiveclassical!
(there are roughtly 500 uses in total); while a number ofcongr
s can be eliminated with this change.