develooper Front page | perl.perl5.porters | Postings from August 2013

Re: postfix dereference syntax

Thread Previous | Thread Next
Ricardo Signes
August 14, 2013 12:01
Re: postfix dereference syntax
Message ID:
* Father Chrysostomos <> [2013-08-14T02:08:00]
> Also, where do we stop?  What about "$my_sub->()"?

We stop at the point where we are no longer keeping postfix syntax in line with
the circumfix forms which already interpolate.  The slope isn't slippery, nor
is it even sloped.  It's about keeping things level.

> Since interpolation juxtaposes code with literal text with no inter-
> vening operators or delimiters, I think it is important to keep it
> conceptually simple.  It is already a mental burden to deal with the
> difference between /$a[1]/ and /$a[123]/.  Please don’t complicate it
> further.  We already have too many exceptions to remember.

« $x->@* acts exactly like @$x » is the rule.  "Except in interpolation" would
be the exception.


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