-
Notifications
You must be signed in to change notification settings - Fork 1
Possibly inconsistent behaviour in mixing-in of 'handles' #894
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
Comments
From @masakOH HAI from NPW::2009. In Rakudo 2c13d6c, the 'handles' instruction on attributes in roles $ perl6 -e 'class A { method foo { say "OH HAI" }; method aie { say I don't think that the above case is mentioned in the spec, but by the By the same token, I guess the following should actually be an error: $ perl6 -e 'class A { method foo { say "OH HAI" }; method aie { say Finally, if the two 'handles' RHSes were regular expressions instead |
From sohtil@gmail.comCurrently both cases cause an error: (Note: It would be awesome if the error message mentioned the $ ./perl6 -e 'class A { method foo { say "OH HAI" }; method aie { say $ ./perl6 -e 'class A { method foo { say "OH HAI" }; method aie { say $ ./perl6 --version This is Rakudo Perl 6, version 2010.07-113-gc41bcd7 built on parrot |
The RT System itself - Status changed from 'new' to 'open' |
From @diakopterOn Thu Apr 16 06:23:35 2009, masak wrote:
this is now fixed. marking testneeded. 17:12 <diakopter> r: class A { method foo { say "OH HAI" }; method aie { |
From @diakopterOn Tue May 29 15:13:18 2012, diakopter wrote:
unmarking testneeded; the classname is now mentioned in the error, but |
From @jnthnOn Thu Apr 16 06:23:35 2009, masak wrote:
The reasoning is a bit off here. Attributes declared in roles are meant to behave much like if they were declared in the class itself. That means that you'd be declaring two attributes $!bar in both of these examples. This today does indeed correctly report a conflict - for both of the code examples. That did leave the issue that we had no tests for if wildcard and literal handles on attributes in roles took effect. I wrote some tests to check they do, and indeed that works out. See the tests added to S14-roles/composition.t in 5a0c386 for the details. |
@jnthn - Status changed from 'open' to 'resolved' |
From @cokeOn Fri Dec 18 08:26:09 2015, jnthn@jnthn.net wrote:
Tests fail on JVM - re-opening ticket, marking JVM only. Fudged test. -- |
@coke - Status changed from 'resolved' to 'open' |
From @usev6With rakudo commit 5435f32949 the test passes again on JVM. I'm closing this ticket. |
1 similar comment
From @usev6With rakudo commit 5435f32949 the test passes again on JVM. I'm closing this ticket. |
@usev6 - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#64766 (status was 'resolved')
Searchable as RT64766$
The text was updated successfully, but these errors were encountered: