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

rotor hangs when given an infinite Seq or List as the cycle #5636

Closed
p6rt opened this issue Sep 2, 2016 · 7 comments
Closed

rotor hangs when given an infinite Seq or List as the cycle #5636

p6rt opened this issue Sep 2, 2016 · 7 comments

Comments

@p6rt
Copy link

@p6rt p6rt commented Sep 2, 2016

Migrated from rt.perl.org#129175 (status was 'resolved')

Searchable as RT129175$

@p6rt
Copy link
Author

@p6rt p6rt commented Sep 2, 2016

From @smls

`rotor` accepts an infinite Range or Array as the cycle​:

  say <a b c d e f>.rotor​: 1..*; # prints ((a) (b c) (d e f))
  say <a b c d e f>.rotor​: (1...*).Array; # prints ((a) (b c) (d e f))

But when given an infinite Seq or List, it hangs indefinitely​:

  say <a b c d e f>.rotor​: 1...*; # hangs
  say <a b c d e f>.rotor​: (1...*).List; # hangs

Loading

@p6rt
Copy link
Author

@p6rt p6rt commented Sep 4, 2016

From @zoffixznet

To add, the cause is .is-lazy on slurpy args seems to attempt to reify the entire sequence​:

-> *@​a { @​a.is-lazy.say }(1…∞) # hangs

Loading

@p6rt
Copy link
Author

@p6rt p6rt commented Sep 4, 2016

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

Loading

@p6rt
Copy link
Author

@p6rt p6rt commented Feb 9, 2017

From @zoffixznet

On Sat, 03 Sep 2016 21​:03​:12 -0700, cpan@​zoffix.com wrote​:

To add, the cause is .is-lazy on slurpy args seems to attempt to reify
the entire sequence​:

-> *@​a { @​a.is-lazy.say }(1…∞) # hangs

The rotor hang fixed in rakudo/rakudo@d7b8214
The slurpy hang fixed in rakudo/rakudo@51b0aba

Marking testsneeded.

Loading

@p6rt
Copy link
Author

@p6rt p6rt commented Feb 9, 2017

From @smls

bisectable revealed that the rotor issue was fixed by​:

  rakudo/rakudo@d7b8214

and the general *@​ slurpy issue was fixed by​:

  rakudo/rakudo@51b0aba

Both probably need tests.

Loading

@p6rt
Copy link
Author

@p6rt p6rt commented Mar 1, 2017

Loading

@p6rt p6rt closed this Mar 1, 2017
@p6rt
Copy link
Author

@p6rt p6rt commented Mar 1, 2017

@zoffixznet - Status changed from 'open' to 'resolved'

Loading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant