in reply to Re: Re: find and replace project with values coming from a table
in thread find and replace project with values coming from a table

I choose for the former because with the given data, the problem doesn't arise. If you want to be able to cope with possible false values (except for 0, the empty string, and undef would be false too) I would use:
$_ = $subs {$_} if exists $subs {$_};

The effect is the same of course, but it looks better IMO.

Abigail

Replies are listed 'Best First'.
Re: Re: find and replace project with values coming from a table
by Aighearach (Initiate) on Jul 06, 2003 at 03:31 UTC
    Agreed, that does look a lot better! It's technically better too, as mine was foolishly replacing $_ with itself in the event of a failed match.
    --
    Snazzy tagline here