Skip to content

fix(lean): fix rendering of impl items with constraints#1850

Merged
abentkamp merged 1 commit intomainfrom
lean-impl-item-fix
Jan 6, 2026
Merged

fix(lean): fix rendering of impl items with constraints#1850
abentkamp merged 1 commit intomainfrom
lean-impl-item-fix

Conversation

@abentkamp
Copy link
Contributor

@abentkamp abentkamp commented Jan 6, 2026

Lean does not accept the following notation:

instance : Y where
  lt [X] := true

In my opinion, this is a Lean bug, but there are simple workarounds, so this will probably not get fixed:
#lean4 > possible parsing bug: invalid {...} notation

This PR implements one of these workarounds.

[skip changelog]

@abentkamp abentkamp added lean Related to the Lean backend or library backend Issue in one of the backends (i.e. F*, Coq, EC...) labels Jan 6, 2026
@abentkamp abentkamp added this to the Lean backend v1.0 milestone Jan 6, 2026
@abentkamp abentkamp marked this pull request as ready for review January 6, 2026 13:08
@abentkamp abentkamp requested a review from a team as a code owner January 6, 2026 13:08
@abentkamp abentkamp added this pull request to the merge queue Jan 6, 2026
Merged via the queue into main with commit eaf0e59 Jan 6, 2026
17 of 18 checks passed
@abentkamp abentkamp deleted the lean-impl-item-fix branch January 6, 2026 15:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend Issue in one of the backends (i.e. F*, Coq, EC...) lean Related to the Lean backend or library

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants