develooper Front page | perl.perl6.language.strict | Postings from February 2001

Re: Warnings, strict, and CPAN

Peter Scott
February 16, 2001 17:50
Re: Warnings, strict, and CPAN
Message ID:
Redirected to -strict to save the sanity of thousands of people who don't care.

At 03:48 PM 2/16/01 -0800, Edward Peschko wrote:
> > Its a fine rationale, but I'm very, very loathe to implicitly split
> > Perl into two seperate languages based on what the filename is.
>Why? Its not the filename, its how its used -
>         require("A"); # library - strict, warnings on
>         use A;        # library - strict, warnings on
>         do "A"        # library - strict, warnings on but who cares, do is
>                       # hardly ever used.
>         eval("\$a = '1'");    # code - strict off
>The functionality for adding 'strict' and 'warnings' would be added onto use
>and require.

This is, what's the word I'm looking for... nuts.  We split code into 
modules for purposes of reuse, not because it's somehow more worthy of 
error checking.  I don't want to have to remember this invisible 
action-at-a-vast-distance rule to figure out why code in different places 
behaves differently wrt pragmas.

Peter Scott
Pacific Systems Design Technologies Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About