SPUG: Last night's meeting
bri at ifokr.org
Wed Mar 17 14:32:27 CST 2004
> I enjoyed the demo, and was reminded that there are some things that
> are better done using perl -d than by print statements.
> > Condemn all debug print statements now!
> IMHO, the humble print statement has a significant advantage over
> any interactive-debugging based strategy, which is simply that it
> will still be there if/when the program breaks again, and it can
> easily be re-activated to deliver its benefits again.
I totally agree with Tim here - debugging print statements are great:
"debug" => \$DEBUG,
print STDERR "random annoying debug statement\n" if $DEBUG;
Just slap those 'if $DEBUG' tags on as needed. Or to save typing
$DEBUG && print STDERR "random annoying debug statement\n";
Also has the benifit of making it obvious as you scan the left hand side
of the script that you need not read this line.
Brian Hatch Two wrongs are
Systems and only the beginning.
Every message PGP signed
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: Digital signature
Url : http://mail.pm.org/pipermail/spug-list/attachments/20040317/e954ce2e/attachment.bin
More information about the spug-list