mrbark has asked for the wisdom of the Perl Monks concerning the following question:
Hi,
I upgraded from perl 5.16 to 5.22.
I have hundreds of scripts that I just cannot modify.
This now fails:
perl -e 'my $var = "hello"; $var =~ s!(?<=\D[01] file)s!!ig;'
It seems that the i option produces the variable length failure because of unicode processing of regexps.
So my question is:
Without modifying this part of code, what can I do to get the same normal behavior I had with 5.16, without downgrading back to 5.16?
I can recompile 5.22 w/ different options if needed.
Thank you!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Lookbehind issues with unicode
by choroba (Cardinal) on Jul 21, 2015 at 16:33 UTC | |
by mrbark (Acolyte) on Jul 21, 2015 at 17:00 UTC | |
|
Re: Lookbehind issues with unicode
by ikegami (Patriarch) on Jul 21, 2015 at 21:43 UTC |