On Wednesday, Mar 26, 2003, at 16:18 America/Caracas, Jeremy Zawodny wrote:


What do other module authors tend to do?  Without a more compelling
reason to change, I'm hesitant to do so.

Well, to put it simply, you should Carp when it is not your fault :) ie, if the exception arises because of a bad parameter, bad usage or similar scenario, warn()ing shows a line in your module as the culprit. This makes it harder for the user to really understand what's going on. By Carp()ing you can point him/her to the correct place in the source (ie, the call to your method).


OTOH, probably combining Carp with registered warnings could be a good thing (tm) so as to allow finer-grained control of the warnings that a given piece of code can emit. You could use those warnings as some sort of conditional debug info, but this is another story.

Regards.

-lem

 --
#!/usr/bin/perl -w
use strict;
$_[$_]=0for 0..7;for$'([EMAIL PROTECTED]@@}unpack"\1028"x28,join'',split//,
qq{=\37\34 \24(\31??\11\64:1\22\36/\24\2\12\4\b??\1\$\2\15\36}){$/=0
;grep{$_[$/++].=$_}split//,$';length$_[0]&@_&&print pack"\1028",$_
[EMAIL PROTECTED];length$_[3]&@_&&grep{$_&[EMAIL PROTECTED];}print"\n";



Reply via email to