develooper Front page | perl.perl5.porters | Postings from June 2021

Re: RFC: Multiple-alias syntax for for

Thread Previous | Thread Next
Dan Book
June 10, 2021 01:38
Re: RFC: Multiple-alias syntax for for
Message ID:
On Wed, Jun 9, 2021 at 7:44 PM Nicolas Mendoza <> wrote:

> 1) since it looks like such an obvious improvement but hasn't been done
> before, is there some reason that one hasn't gone down this route
> before? Are there some hidden gotchas about it? Or is it just genius
> overlooked simplification?

I suspect no proposal has gotten far enough in implementation yet to be
usefully discussed.

> 2) will this work flawlessly with for instance: for my ($key $value,
> %rest) = (%hash) { … } (iterating only once)

I don't see why this should be supported and complicate the implementation,
since you can just do that assignment without any loop.

> 3) will it work transparently with foreach (I believe I saw some
> comments about that)

Not sure what you mean; this is a feature specifically for foreach.


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About