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

Enforce uniform indentation in tactic blocks / do blocks / sepByIndent #1606

Closed
gebner opened this issue Sep 15, 2022 · 1 comment · Fixed by #1622
Closed

Enforce uniform indentation in tactic blocks / do blocks / sepByIndent #1606

gebner opened this issue Sep 15, 2022 · 1 comment · Fixed by #1622

Comments

@gebner
Copy link
Member

gebner commented Sep 15, 2022

The use of colGe to implement indentation-sensitive syntax can lead to extremely surprising parses:

example : false := by
  conv =>
    lhs
    dsimp
    simp

Namely if dsimp is a conv-tactic then this parses as three conv-tactics (like the indentation suggests). But if dsimp is not a conv-tactic, then this parses as (conv => lhs); dsimp; simp.

We should try out whether a colEq combinator (that enforces uniform indentation) causes any unexpected issues.

Another option (that fixes the particular issue here) would be to implement a fallback elab ident : conv => throwError "unknown conv tactic" like we have for tactic.

@leodemoura
Copy link
Member

We should try out whether a colEq combinator (that enforces uniform indentation) causes any unexpected issues.

I like this.

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.

2 participants