|Just another Perl shrine|
Re^4: Some thoughts around the "is Perl code maintainable" discussionby renormalist (Sexton)
|on Aug 14, 2007 at 09:40 UTC ( #632434=note: print w/replies, xml )||Need Help??|
> One thing that is occasionally annoying is the
> confusion between "multi line" anonymous hashrefs and
> code blocks: to cope with that I often put parentheses
> instead, that I substitute with curlies later. Not
> terribly hard, but... well, annoying.
In my extensions to cperl-mode for Perl6 syntax (and here) I made a Perl6 like distinction between hashes and blocks in a way that no whitespace is allowed before the curlies of hashes. With that the distinction of hashes and blocks generally works better.
I always use my enhanced variant of cperl-mode also for Perl5 code due to features like this, so maybe you also give it a try.
In Section Meditations