[Melbourne-pm] WTF were they thinking?

Mathew Robertson mathew.blair.robertson at gmail.com
Tue Nov 29 16:58:39 PST 2011

On 29 November 2011 23:54, Andrew Pam <andrew at sericyb.com.au> wrote:

> On 29/11/11 23:29, Tim Connors wrote:
> >
> http://blogs.perl.org/users/rurban/2010/09/qw-in-list-context-deprecated.html
> >
> > Does anyone know whether this was completely arbitrary, or whether there
> > was good logic behind this change?
> Explained quite well in the comments, I thought?
Not really...   'for' is a statement, not a function.  If that were the
case 'if ...' and 'print ...' and so on, should also require parens... '

Alternatively... 'for' takes a list as its third (or second) argument, qw//
provides that.  Parens is only syntactic sugar for generating a list. For
example (arguably) this should also work, but the parsing would be almost

for keys %hash { print $_ }

My $0.02 -> the core developers should be making Perl faster (and fixing
bugs), as highlighted by the recent comparison on this mailing list.  I
know that in the past, I have moved code to a different language for a
speed increase, once the business rules had stabilized.

Mathew Robertson
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.pm.org/pipermail/melbourne-pm/attachments/20111130/9da24acc/attachment.html>

More information about the Melbourne-pm mailing list