Skip to content
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

Cannot slice a Range that is bound to an array variable #2649

Open
p6rt opened this issue Feb 20, 2012 · 6 comments
Open

Cannot slice a Range that is bound to an array variable #2649

p6rt opened this issue Feb 20, 2012 · 6 comments
Labels

Comments

@p6rt
Copy link

p6rt commented Feb 20, 2012

Migrated from rt.perl.org#111164 (status was 'open')

Searchable as RT111164$

@p6rt
Copy link
Author

p6rt commented Feb 20, 2012

From @moritz

16​:06 < moritz> nom​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
16​:06 <+p6eval> nom 4130f6​: OUTPUT«Method 'gimme' not found for invocant of
  class 'Range'␤ in method postcircumfix​:<[ ]> at
  src/gen/CORE.setting​:1159␤ in block <anon> at
  /tmp/dJ08aEvIzI​:1␤␤»

Since ~~ Positional in Rakudo, I see no reason why this shouldn't work,
much less with such an obscure error message.

@p6rt
Copy link
Author

p6rt commented May 30, 2012

From @diakopter

On Mon Feb 20 07​:10​:45 2012, moritz wrote​:

16​:06 < moritz> nom​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
16​:06 <+p6eval> nom 4130f6​: OUTPUT«Method 'gimme' not found for
invocant of
class 'Range'␤ in method postcircumfix​:<[ ]> at
src/gen/CORE.setting​:1159␤ in block <anon> at
/tmp/dJ08aEvIzI​:1␤␤»

Since ~~ Positional in Rakudo, I see no reason why this shouldn't
work,
much less with such an obscure error message.

now it times out.

19​:16 <diakopter> r​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
19​:16 <p6eval> rakudo 024843​: OUTPUT«(timeout)»

@p6rt
Copy link
Author

p6rt commented May 30, 2012

The RT System itself - Status changed from 'new' to 'open'

@p6rt
Copy link
Author

p6rt commented Feb 9, 2015

From @Mouq

Shouldn't it timeout, in this case? @​a[0] is @​a[1] is @​a[3] is @​a[7] is @​a[5]…

On Tue May 29 17​:16​:40 2012, diakopter wrote​:

On Mon Feb 20 07​:10​:45 2012, moritz wrote​:

16​:06 < moritz> nom​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
16​:06 <+p6eval> nom 4130f6​: OUTPUT«Method 'gimme' not found for
invocant of
class 'Range'␤ in method postcircumfix​:<[ ]> at
src/gen/CORE.setting​:1159␤ in block <anon> at
/tmp/dJ08aEvIzI​:1␤␤»

Since ~~ Positional in Rakudo, I see no reason why this shouldn't
work,
much less with such an obscure error message.

now it times out.

19​:16 <diakopter> r​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
19​:16 <p6eval> rakudo 024843​: OUTPUT«(timeout)»

@p6rt
Copy link
Author

p6rt commented Aug 27, 2015

From @coke

On Sun Feb 08 22​:55​:34 2015, Mouq wrote​:

Shouldn't it timeout, in this case? @​a[0] is @​a[1] is @​a[3] is @​a[7]
is @​a[5]…

On Tue May 29 17​:16​:40 2012, diakopter wrote​:

On Mon Feb 20 07​:10​:45 2012, moritz wrote​:

16​:06 < moritz> nom​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
16​:06 <+p6eval> nom 4130f6​: OUTPUT«Method 'gimme' not found for
invocant of
class 'Range'␤ in method postcircumfix​:<[ ]> at
src/gen/CORE.setting​:1159␤ in block <anon> at
/tmp/dJ08aEvIzI​:1␤␤»

Since ~~ Positional in Rakudo, I see no reason why this shouldn't
work,
much less with such an obscure error message.

now it times out.

19​:16 <diakopter> r​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
19​:16 <p6eval> rakudo 024843​: OUTPUT«(timeout)»

Currently still times out in glr branch.
--
Will "Coke" Coleda

@p6rt
Copy link
Author

p6rt commented Dec 2, 2017

From @AlexDaniel

As of (2017.11, HEAD(5929887)) it errors out​:

Code​:
say (1..*)[1, 3 … *]

Result​:
Cannot .elems a lazy list
  in block <unit> at -e line 1

Is the intention of the OP that it should work? I don't think so.

On 2015-08-27 06​:01​:23, coke wrote​:

On Sun Feb 08 22​:55​:34 2015, Mouq wrote​:

Shouldn't it timeout, in this case? @​a[0] is @​a[1] is @​a[3] is @​a[7]
is @​a[5]…

On Tue May 29 17​:16​:40 2012, diakopter wrote​:

On Mon Feb 20 07​:10​:45 2012, moritz wrote​:

16​:06 < moritz> nom​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
16​:06 <+p6eval> nom 4130f6​: OUTPUT«Method 'gimme' not found for
invocant of
class 'Range'␤ in method postcircumfix​:<[ ]> at
src/gen/CORE.setting​:1159␤ in block <anon> at
/tmp/dJ08aEvIzI​:1␤␤»

Since ~~ Positional in Rakudo, I see no reason why this shouldn't
work,
much less with such an obscure error message.

now it times out.

19​:16 <diakopter> r​: my @​a := 1..*; @​a := @​a[1, 3 ... *].list
19​:16 <p6eval> rakudo 024843​: OUTPUT«(timeout)»

Currently still times out in glr branch.

@p6rt p6rt added the at_larry label Jan 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant