# New Ticket Created by Kaz Wesley # Please include the string: [perl #110654] # in the subject line of all future correspondence about this issue. # <URL: https://rt.perl.org:443/rt3/Ticket/Display.html?id=110654 >
> my @spam = gather loop { take 'eggs'; last } Method 'eager' not found for invocant of class 'Integer' Tried this with "perl6 version 2011.12 built on parrot 3.11.0 revision 0" and with the current git head: "perl6 version 2012.01-140-g91c3326 built on parrot 4.0.0 revision RELEASE_4_0_0-85-g8a1265a". I mentioned in on IRC; here's the log of that discussion: (11:46:24 PM) TimToady: perl6: my @spam = gather loop { take 'eggs'; last }; say @spam (11:46:29 PM) p6eval: rakudo bd5adb: OUTPUT«Method 'eager' not found for invocant of class 'Integer' in block <anon> at /tmp/B6jpxyUQ0v:1» (11:46:29 PM) p6eval: ..pugs b927740, niecza v14-42-g1d02da9: OUTPUT«eggs» (11:46:37 PM) TimToady: I'd say you're right (11:47:43 PM) TimToady: the eager likely comes from the assignment, but I've no idea where the Integer comes from--looks like a Parrot type (11:48:34 PM) kcw: k. I'll submit it to perlbug. Glad to see I'm not just misunderstanding something; I've been trying to figure out why this doesn't work for a while. (11:49:04 PM) TimToady: nom: my @spam = gather while 1 { take 'eggs'; last }; say @spam (11:49:06 PM) p6eval: nom bd5adb: OUTPUT«eggs» (11:49:17 PM) TimToady: hmm (11:49:39 PM) TimToady: nom: my @spam = gather loop (;1;) { take 'eggs'; last }; say @spam (11:49:40 PM) p6eval: nom bd5adb: OUTPUT«eggs» (11:49:52 PM) TimToady: seems like there's a hint (11:50:11 PM) TimToady: nom: my @spam = gather loop (;;) { take 'eggs'; last }; say @spam (11:50:13 PM) p6eval: nom bd5adb: OUTPUT«Method 'eager' not found for invocant of class 'Integer' in block <anon> at /tmp/7pxw9NGc3l:1» (11:50:28 PM) TimToady: I'd say the default condition is a Parrot type rather than a Perl type