Skip to content

Conversation

@axelf4
Copy link
Contributor

@axelf4 axelf4 commented Feb 22, 2021

Makes parsing not fail for case expressions that match multiple expressions at once, such as

case a, b of
  Just 1, Just 1 -> 1
  _, _ -> 0

This syntax was added in PureScript v0.8.0.

See: https://github.com/purescript/documentation/blob/master/language/Syntax.md#case-expressions

Makes parsing not fail for case expressions that match multiple
expressions at once, such as

    case a, b of
      Just 1, Just 1 -> 1
      _, _ -> 0

This syntax was added in PureScript v0.8.0.

See: https://github.com/purescript/documentation/blob/master/language/Syntax.md#case-expressions
@gomain
Copy link

gomain commented Jun 27, 2021

Why is this not merged? Is it pending for review?

@gomain
Copy link

gomain commented Jun 27, 2021

I can't get this to work. Still Parse error when press tab on multi value match expression. Any suggestions?

@axelf4
Copy link
Contributor Author

axelf4 commented Jun 27, 2021

I can't get this to work. Still Parse error when press tab on multi value match expression. Any suggestions?

Could you give a MWE? My guess is that you are running into some other issue. For example, record literals interact poorly with explicit layout.

@gomain
Copy link

gomain commented Jun 27, 2021

My guess is that you are running into some other issue. For example, record literals interact poorly with explicit layout.

You're right. It's this

test a
  = let { b } = a
     in b -- parse error since here

Multi match case work fine. Submitted #12.

Thank you for your patch.

@kritzcreek
Copy link
Contributor

Thank you, sorry for the long wait.

@kritzcreek kritzcreek merged commit eacc61a into purescript-emacs:master Mar 9, 2023
@axelf4 axelf4 deleted the multi-case-expr branch March 9, 2023 13:06
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.

3 participants