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

Strange behavior with FIRST + while block + required parameter #6505

Open
p6rt opened this issue Sep 9, 2017 · 1 comment
Open

Strange behavior with FIRST + while block + required parameter #6505

p6rt opened this issue Sep 9, 2017 · 1 comment
Labels

Comments

@p6rt
Copy link

p6rt commented Sep 9, 2017

Migrated from rt.perl.org#132050 (status was 'new')

Searchable as RT132050$

@p6rt
Copy link
Author

p6rt commented Sep 9, 2017

From @ugexe

while $(1,2) -> @​_ { FIRST { say 42 }; say @​_; last if ++$ }
# Too few positionals passed; expected 1 argument but got 0

while $(1,2) -> @​_ { LAST { say 42 }; say @​_; last if ++$ }
# (1 2)
# 42

while $(1,2) -> $_ { FIRST { say 42 }; say $_; last if ++$ }
# Too few positionals passed; expected 1 argument but got 0

while $(1,2) -> *@​_ { FIRST { say 42 }; say @​_; last if ++$ }
# 42
# []

while $(1,2) -> $_? { FIRST { say 42 }; say $_; last if ++$ }
# 42
# (Mu)

https://irclog.perlgeek.de/perl6-dev/2017-09-09#i_15140996

@p6rt p6rt added the Bug 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