-
Notifications
You must be signed in to change notification settings - Fork 118
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
Documentation for alias is incorrect, cannot take String #23
Comments
Thanks for the report, I wasn't able to find this file in the current documentation. Can you send me a link? Unfortunately we don't maintain ruby-doc.org, so I don't have access to their files. After testing, you can't pass a string to def foo
"zomg"
end
alias "bar" foo #=> SyntaxError: (irb):10: syntax error, unexpected tSTRING_BEG
alias :bar foo
bar #=> "zomg"
# notice it creates a local variable named bar (used without the symbol syntax)
alias undefined foo
undefined #=> "zomg" |
@zzak Can you find where |
@dblock I started working on a If you're interested I can open a work in progress pull request and you can fork my branch if you'd like to help? |
Def. open an issue and cc: me on it. Making no promises, but seems like it's something needed so me or someone will pick it up. |
Giving this a close since there has been no further update. Anyone is welcome to improve the docs for keywords. |
http://ruby-doc.org/docs/keywords/1.9 incorrectly states that arguments to
alias
can beString
. See rubocop/rubocop#657. I spent a long time trying to figure out whetheralias
in the current tree.Help?
The text was updated successfully, but these errors were encountered: