in reply to Conditional Regex
Not sure what conditionals buy you here:
sub getvalue { my $s = shift; local $_ = shift; return $+ if /$s[:=](?:(\d+)|"([^"]+)"|\s*(.*?)\s\D)/; "Match not Found"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Conditional Regex
by hsmyers (Canon) on Jan 09, 2004 at 15:26 UTC |