Skip to content

Conversation

@TauOmicronMu
Copy link
Collaborator

Closes #61

Copy link
Contributor

@david-christiansen david-christiansen left a comment

Choose a reason for hiding this comment

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

It's OK as is, but I suggested a minor tweak to the wording

introduced: 9.6.1
---

Pattern matching allows constructors and literals to be used to take apart values, exposing their contents. The `let ... in ...` syntax is used to introduce declarations that are scoped to an expression. See [GHC-04584](https://errors.haskell.org/messages/GHC-78892/) for more information on why expressions aren't permitted in pattern matching.
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
Pattern matching allows constructors and literals to be used to take apart values, exposing their contents. The `let ... in ...` syntax is used to introduce declarations that are scoped to an expression. See [GHC-04584](https://errors.haskell.org/messages/GHC-78892/) for more information on why expressions aren't permitted in pattern matching.
Pattern matching allows constructors and literals to be used to take apart values, exposing their contents. Even though patterns resemble expressions, they are not evaluated. The `let ... in ...` syntax is used to introduce declarations that are scoped to an expression, which doesn't make sense as a pattern without evaluation. See [GHC-04584](https://errors.haskell.org/messages/GHC-78892/) for more information on why expressions aren't permitted in pattern matching.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Changed :)

@david-christiansen
Copy link
Contributor

Thanks!

@david-christiansen david-christiansen merged commit fff62b8 into haskellfoundation:main Jun 22, 2023
@david-christiansen
Copy link
Contributor

Thank you again :-)

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.

PsErrLetInPat -> 78892

2 participants