P is for Practical | |
PerlMonks |
Re: Re: Re: Dynamic regexp from array valuesby broquaint (Abbot) |
on Feb 12, 2003 at 12:16 UTC ( [id://234659]=note: print w/replies, xml ) | Need Help?? |
Actually my $regex = qr(join '|', map "\Q$_\E", @vals) will optimize the pattern matchingHrm, that's debatable, check out diotalevi's reply in meaning of /o in regexes. HTH
_________
In Section
Seekers of Perl Wisdom
|
|