Re: Parse a string into a regex?

2017-05-12 Thread Lloyd Fournier
Patrick's answer of <$regex-interpolation> is the one I'd use. Although it checks a few possibly malicious things it doesn't catch everything: https://rt.perl.org/Public/Bug/Display.html?id=131079 On Fri, May 12, 2017 at 5:11 PM Andreas Mueller < andreas.muel...@biologie.uni-osnabrueck.de> wrote:

Re: Parse a string into a regex?

2017-05-12 Thread Andreas Mueller
IMHO it is a security and speed issu I switched it of with a pragma like this: use MONKEY-SEE-NO-EVAL; my $match = EVAL "/$m/"; if $test_string ~~ $match { say 'yea' } Andreas On 11.05.17 10:32, Sean McAfee wrote: > I've been searching for how to parse a string into a regex