develooper Front page | perl.perl5.porters | Postings from January 2008

Re: 5.11 (or 12) and strict

Thread Previous | Thread Next
From:
Moritz Lenz
Date:
January 3, 2008 02:23
Subject:
Re: 5.11 (or 12) and strict
Message ID:
477CAD9D.3070301@casella.verplant.org
Sean O'Rourke wrote:
> Steffen Mueller <l2ot9pa02@sneakemail.com> writes:
>> If you write enough code to make importing optional features
>> worthwhile, odds are very high you'd be importing "strict"
>> anyway.
> 
> I'm not a p5p regular or a Perl core developer, so you definitely
> can, probably will, and possibly should ignore me.
> 
> That being said, the above quote basically says "if you want to
> use some desirable feature (like given/when) that is in Perl >
> 5.10, you must accept this other feature (strictures) P5P deems
> healthy," which seems strangely authoritarian.

You can still say
no strict;
after importing 5.10 (or 5.1\d) features. Or you can selectively import
the shiny new 5.1\d features that you want to use.

>  People who want
> all the code on their own systems to run with strict can set
> PERL5OPT in /etc/profile.  Those who want all the code on other
> people's systems to do so are mistaken.

And what about other's code on your own system? It would break. D'oh.
And notice that you can't simply decide not to run other people's code,
because your operating system likely does it for you (for example the
package manager).

Anyway, +1 from me for "use 5.010" implying "use strict".

Moritz

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About