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

Show the pattern matching else syntax #174

Merged
merged 3 commits into from
Apr 8, 2021

Conversation

eric-wieser
Copy link
Member

No description provided.

@eric-wieser
Copy link
Member Author

@digama0 or @bryangingechen, mind taking a look?

Copy link
Collaborator

@bryangingechen bryangingechen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't know about this syntax either!

@digama0
Copy link
Member

digama0 commented Mar 3, 2021

I would avoid comparing <|> to | as they are really quite different syntactically and semantically. <|> is a regular binary infix operator that fails if both of the inputs fail, while | is a part of the a <- m | m2, syntax inside a do block, and the result of m2 goes to the return of the tactic rather than bound into a.

@eric-wieser
Copy link
Member Author

Sure, they're quite different operators - but I suspect lots of people reach for <|> when what they really want is |, so I think it makes sense to keep them together. I'll see if I can reword slightly.

@eric-wieser
Copy link
Member Author

@digama0, does this look better?

@eric-wieser eric-wieser requested a review from digama0 April 1, 2021 11:45
@PatrickMassot PatrickMassot merged commit dcd71a6 into leanprover-community:newsite Apr 8, 2021
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 this pull request may close these issues.

None yet

4 participants