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

better variables mass assigment #3059

Closed
kostya opened this issue Jul 28, 2016 · 1 comment
Closed

better variables mass assigment #3059

kostya opened this issue Jul 28, 2016 · 1 comment

Comments

@kostya
Copy link
Contributor

kostya commented Jul 28, 2016

right now this is raised:

a, b = "bla\n".chomp.split("|||")

would be nice if it work like this:

a, b? = "bla\n".chomp.split("|||")
a # => "bla"
b # => nil
@asterite
Copy link
Member

@kostya It seems we had the same idea and the same syntax :-) #2617

So I guess that a 👍 to my proposal :-D

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

2 participants