Phoenix.pm: quoting constant hash keys survey

Andrew Johnson aj at exiledplanet.org
Sat Apr 17 15:33:13 CDT 2004


Scott Walters wrote:

Scott, I can tell you without hesitation that I /hate/ this.  Mostly for 
the cons you've already specified.

[snip]

>Cons:
>
>* %foo`bar doesn't look like a hash subscript if you're used to %foo{'bar'}
>
>* Could be used to write really terse code
>
>* Ugly
>
>* Perl 6 already has 2 ways to subscript hashes now, 3 is too many
>
>  
>
I agree wholeheartedly here, and with the poster that said, "call it 
something besides Perl 6."  One of the goals of Perl 6 was supposed to 
be a /decreased complexity/ in certain areas.  Elimination of synonyms, 
removal of old cruft.  Having the backtick suddenly be the hash 
subscript operator is bad because most people now see the backtick and 
think "shell command."  With this, now they'll have to think, "shell 
command unless there's only one, then it's a hash key."  And hash keys 
are everywhere in most large Perl 5, and my impression is they'll 
continue to be in Perl 6.  This is too much alienation of the existing 
Perl programmer community.

And it is very ugly, IMHO, the ` and the << >> syntax.  And if Perl 6 
does indeed already have 2 ways to subscript hashes, adding a third 
violates the simplification though synonym elimination.

>* People who really want something like that can extend the language using Perl 6's
>equivilent to source filters
>
>  
>
Agreed.

Don't get me wrong here:  I like the idea of re-evaluating things in the 
language.  But there are several things in Perl 6 I don't like because I 
think they go too far, and if this were implemented, I'd add it to the 
"don't like" list immediately.





More information about the Phoenix-pm mailing list