Skip to content

Fix #2149, remove support for = in ObjectBinder#2152

Merged
paf31 merged 2 commits into0.9from
2149
May 22, 2016
Merged

Fix #2149, remove support for = in ObjectBinder#2152
paf31 merged 2 commits into0.9from
2149

Conversation

@paf31
Copy link
Copy Markdown
Contributor

@paf31 paf31 commented May 22, 2016

No description provided.

@paf31 paf31 added this to the 0.9.0 milestone May 22, 2016
@garyb
Copy link
Copy Markdown
Member

garyb commented May 22, 2016

👍

do name <- lname
b <- P.option (VarBinder (Ident name)) rest
return (name, b)
<|> (,) <$> stringLiteral <*> rest
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

What's happening here now?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This is the same as before. I thought it could be changed, but I changed it back.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

What's actually happening here in the first place? 😄 I don't quite understand what the stringLiteral is doing here.

Copy link
Copy Markdown
Contributor Author

@paf31 paf31 May 22, 2016

Choose a reason for hiding this comment

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

You can have { foo: bar } or { foo } or { "!!!": baz }, but not { "!!!" }, since that wouldn't be a valid Ident.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Ohh, right, I got confused... I'm not sure what I was thinking, but I didn't notice that parseIdentifierAndBinder is only for record pairs.

@paf31 paf31 merged commit e7ddf82 into 0.9 May 22, 2016
@paf31 paf31 deleted the 2149 branch May 22, 2016 22:52
@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 56.256% when pulling 3366ae8 on 2149 into ddd8101 on 0.9.

archaeron pushed a commit to archaeron/purescript that referenced this pull request Apr 6, 2017
…#2152)

* Fix purescript#2149, remove support for = in ObjectBinder

* Extended matches must specify a binder
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants