[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] Off-topic: Use of the 'strict' pragma



At 17.24 -0500 1999.03.10, Elton Hughes wrote:
>This is an off-topic post. For those who would like to continue the
>discussion, I recommend that we move this to macperl-anyperl.

I think it is fine here, personally.


>1. Am I correct in assuming that the larger the project, the more likely
>strict is used? Or, in the real world do some programmers just ignore it?

I think so.


>2. Is strict, too strict? (This is hinted at, but I value your comments.)

Sometimes.  I will occasionally need to do things that require me to turn
off strict.  But you can do it:

  use strict;

  {
    no strict 'vars';
    $x = 1;     # ok
    print $x;   # ok
  }

  print $x;  # not ok


>3. Once development is complete, can you save some (loading|run)time by
>commenting out strict?

Nah.

>4. Should one 'use strict;' encompassing 'vars', refs', and 'subs'? When
>should a programmer get specific?

I leave strict on all the time unless I need to disable it, and then I
disable something specifically.

--
Chris Nandor          mailto:pudge@pobox.com         http://pudge.net/
%PGPKey = ('B76E72AD', [1024, '0824090B CE73CA10  1FF77F13 8180B6B6'])

===== Want to unsubscribe from this list?
===== Send mail with body "unsubscribe" to macperl-request@macperl.org