You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
m: class C { method foo (--> ::?CLASS:D) { self } }; say .foo given C
rakudo-moar 080630: OUTPUT«(C)»
Expected: typecheck failure, since `self` is not :D
And using ::?CLASS:D in the body of the method errors out, saying you
can't adverb ::?CLASS:
m: class C { method foo (--> ::?CLASS:D) { say (::?CLASS:D).HOW; self;
} }; say .foo given C
rakudo-moar 080630: OUTPUT«5===SORRY!5=== Error while compiling
<tmp>You can't adverb ::?CLASSat <tmp>:1------> 3d foo (-->
::?CLASS:D) { say (::?CLASS:D7⏏5).HOW; self; } }; say .foo given C
expecting any of: pair value»
Migrated from rt.perl.org#130151 (status was 'new')
Searchable as RT130151$
The text was updated successfully, but these errors were encountered: