But sometimes it is necessary to turn it off, e.g.
My workflow still provides this all, but is a lot easier. Using Dist::Milla by Miyagawa is the secret.
]]>$count++ while(<$filehandle>)]]>
I tried $count++ while() against 'wc -l'. On a file with 3 mio. lines it's 0.466s versus 0.087s on a Mac Air, but on a small file with 6 lines it's 0.006s versus 0.018s. IMHO the pure perl version has pros than cons.
]]>$ perl -e 'print join("\t",(map{`wc -l $_`} grep{-f}map{chomp;$_}(`ls -1t`))[0]=~/(\S+)/g),"\n";' 6 title_12_1832.txt
As script-snippet:
my $dir = "."; my ($lines,$file) = ( map { `wc -l $_` } grep { -f "$dir/$_" } map { chomp; $_ } (`ls -1t "$dir"`) )[0] =~ /(\S+)/g;]]>
This is reproducable.
]]>What exactly are you doing?
Test::Pretty also exists as App::Prove::Plugin, thus can come via prove (.proverc, ENV, -Pretty ...).
]]>I wonder if Larry intended to imitate the behaviour of another language. Or if this is Larryish syntactic sugar. Or a bug.
]]>if () {}
gives a syntax error, there must be a bug in while or if, or the docs are wrong.
Compare this:
$ perl -e '$c = () ? 1 : 2;print $c,"\n";' 2
From the docs I would expect an empty expression to evaluate to undef.
]]>Yes, it should be a CPANTS/Kwalitee metric. It compares to use strict, where also are good reasons in some cases for no strict.
]]>Tie::Handle seems repaired in a backwards compatible way. Why not the other Tie::* ones?
]]>