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

Parser rejects some heredoc in hash literal #4815

Closed
hanazuki opened this issue Nov 10, 2019 · 0 comments
Closed

Parser rejects some heredoc in hash literal #4815

hanazuki opened this issue Nov 10, 2019 · 0 comments

Comments

@hanazuki
Copy link

The following code fragments are accepted by MRI but rejected by mruby. I found it quite inconvenient that long multiline strings cannot be directly included in a hash.

{a: <<X,
X
b: 1}

{a: <<X, b:
X
1}

Tested on cc54257

@matz matz closed this as completed in 943fbb2 Jan 1, 2020
matz added a commit that referenced this issue Sep 13, 2021
`{x:, y:}` now is a syntax sugar of `{x: x, y: y}`.

This fix also includes the update of #4815 fix.
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

No branches or pull requests

1 participant