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

#check issue with native_decide #2072

Closed
1 task done
arthur-adjedj opened this issue Jan 29, 2023 · 0 comments · Fixed by #5999
Closed
1 task done

#check issue with native_decide #2072

arthur-adjedj opened this issue Jan 29, 2023 · 0 comments · Fixed by #5999

Comments

@arthur-adjedj
Copy link
Contributor

arthur-adjedj commented Jan 29, 2023

Prerequisites

  • Put an X between the brackets on this line if you have done all of the following:
    • Checked that your issue isn't already filed.
    • Reduced the issue to a self-contained, reproducible test case.

Description

Using native_decide in #check can trick #check into believing something is well-typed when it shouldn't be, The following code doesn't raise any error:

#check show False by native_decide

See associated Zulip thread

Steps to Reproduce

Expected behavior:
#check should reject this and give an error

Actual behavior:
#check acts as if the term produced was well-formed, and prints this:

let_fun this := of_decide_eq_true (Lean.ofReduceBool _check._nativeDecide_1 true (Eq.refl true));
this : False

Reproduces how often:
100%

Versions

4.0.0-nightly-2023-01-16
Windows 11

github-merge-queue bot pushed a commit that referenced this issue Nov 8, 2024
This PR adds configuration options for
`decide`/`decide!`/`native_decide` and refactors the tactics to be
frontends to the same backend. Adds a `+revert` option that cleans up
the local context and reverts all local variables the goal depends on,
along with indirect propositional hypotheses. Makes `native_decide` fail
at elaboration time on failure without sacrificing performance (the
decision procedure is still evaluated just once). Now `native_decide`
supports universe polymorphism.

Closes #2072
JovanGerb pushed a commit to JovanGerb/lean4 that referenced this issue Jan 21, 2025
…r#5999)

This PR adds configuration options for
`decide`/`decide!`/`native_decide` and refactors the tactics to be
frontends to the same backend. Adds a `+revert` option that cleans up
the local context and reverts all local variables the goal depends on,
along with indirect propositional hypotheses. Makes `native_decide` fail
at elaboration time on failure without sacrificing performance (the
decision procedure is still evaluated just once). Now `native_decide`
supports universe polymorphism.

Closes leanprover#2072
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

Successfully merging a pull request may close this issue.

1 participant