-
Notifications
You must be signed in to change notification settings - Fork 288
Split 5to6 section into 3 paragraphs #4559
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
base: main
Are you sure you want to change the base?
Conversation
The dereferencing operator, C«->», is replaced by the dot, which is | ||
also used for method calls. So Perl's C«$arrayref->[7]» becomes | ||
Raku's C<$arrayref.[7]> and C«$user->name» becomes C<$user.name>. | ||
Note that dereferencing is rare in Raku. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps add: and that $arrayref[7]
is also valid syntax for positional access (losing the dot).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do not understand this well. A few times, IIRC, I have needed a dot to get an array index to work. I am fairly sure that it was in map
's Callable parameter. So there is something like indirection that comes up rarely. JJ seems to be making that distinction.
If that distinction is real, your addition would be better placed with 5to6's guidance about Arrays.
I'll try checking the dot-reference-op's sources, with modest hope of success.
|
It would help if I had a bit of context. Are you talking about an issue, about what's actually written there which I wrote (found by blame)? I'll try to go for both, but will need some time figuring out, I'm afraid. |
OK, I have a bit of context here now. My 2¢ (taking into account that the only thing I did with this piece of documentation is changing Perl(non-breaking-whitespace)6 to raku)
|
@JJ, You have my apology for my poor blame reading. Whenever altering the docs or code, I will try to improve the readability, that includes tone, brevity, flow, and use of an extended international English. I think mentioning Raku's use of If there is no dereferencing happening with the dot, then that can be deleted. What confuses me is the applicability of this "dereferencing" to: |
Split the Language/5to6-perlop/The_arrow_operator section into 3 paragraphs.
Changed the
fat arrow
redirect to the more local 5to6-perlop#Comma_operator. And put it first.Reduced the text of the central point into the second paragraph. Making a change so the first sentence need not be corrected by the second.
The third pargraph briefly states the
->
's Raku purpose with links.My "dereferencing is rare in Raku" seems justified in my slight experience and by JJ's tone. If not so, advise.