# New Ticket Created by  Lithos 
# Please include the string:  [perl #77072]
# in the subject line of all future correspondence about this issue. 
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=77072 >


Hi!

In @a[*], * should mean all indexes of @a, but this does not work in
Rakudo, currently:


#perl6 2010-08-07
14:01 lithos       hello #perl6! is @a[*] supposed to work for
indexing the one-past-last element of an array?
14:02 sorear       no
14:02 TimToady     * means all the indexes
14:03 TimToady     so it should mean @a[0,1,2] = 4
14:03 lithos       ah, thanks
14:04 lithos       rakudo: my @a = 1, 2, 3; @a[*] = (4, 5, 6); say ~...@a;
14:04 p6eval       rakudo 6ebba8: OUTPUT«Can't take numeric value for
object of type Whatever␤  in 'Any::Numeric' at line 1351:CORE.setting␤
 in 'infix:<<>' at line 6573:CORE.setting␤  in 'Any::postcircumfix:<[
]>' at line 1665:CORE.setting␤  in main program body at line 1␤»


$ ./perl6
> my @a = 1,2,3;
1 2 3
> say ~...@a[0,1,2];
1 2 3
> say ~...@a[*];
Can't take numeric value for object of type Whatever


$ ./perl6 --version

This is Rakudo Perl 6, version 2010.07-86-ge569d66 built on parrot 2.6.0 r48225

Reply via email to