[Israel.pm] Re: Variable Naming

Mikhael Goikhman migo at homemail.com
Wed Jun 9 09:06:53 PDT 2004

On 07 Jun 2004 23:56:16 +0300, Yuval Yaari wrote:
> > You are right - it does not necessarily mean that it's better. However
> > to  quote from "perldoc perlstyle":
> perlstyle is highly respected by me

Yes, every Perl programmer should read this document (and perltoot too),
although it includes some questionable points. For example, it is funny
how the author suggests to outdent the "last" operator. :)

> I didn't read it for quite some time now, but what comes to mind at this
> time is the tab-stop length of 4.
> I use 8 for better readability.

Yes, hardcoding the tab size (or otherwise indention) to 2, 4 or 8 spaces
is obnoxious. A good code may use real tabs and still look correctly with
any tab size. At least all my code looks correctly with any tab size.

This is the reason why auto-indentation with hardcoded indention (as
found in emacs or vim, either mixed spaces+tabs or spaces) is evil, and
better be disabled. One may use just two keys to produce a perfectly
structured code, real-Tab to add an indentation level and real-Backspace
to delete it. Long line may be continued on the next indentation level.

Unfortunately this is not going to happen everywhere, people just use the
style that their "smart" editors force on them and thus we have the tab
size disputes.


perl -e 'print+chr(64+hex)for+split//,d9b815c07f9b8d1e'

More information about the Perl mailing list