On Sat, Aug 23, 2003 at 01:55:03PM +0200, Marcel Greter wrote:
This is not a very good solution. You would also catch the case where $_ is 0, which may should not happen. You would better do
Yes... I always fall into that pithole. I think this is because I find the 'defined(...) ? ... : ...' phrase is kinda ugly. Silly me, I know.
$_ = defined $_ ? $_ : "NULL";
perl 5.9 has introduced a new operator //= to make it spiffy, so you'd write the above as:
$_ //= "NULL";
__________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
-- Reporting bugs: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html