in reply to Re^2: Why aren't perl regular expressions really regular expressions?
in thread Why aren't perl regular expressions really regular expressions?
I.o.W the syntax looks compatible but the results may not in edge cases.
Exactly. The basic features are probably in place - I say "probably", as I've not actually looked at the pcre library -, but not all of the advanced features will be. At the very least I would expect that match-time code evaluation isn't; if you have a regular expression using that in a Perl program, I'd bet you will not be able to copy it unmodified to a script written in another language and having it Just Work™.
It's not gonna matter most of the time (famous last words, those), but one should still keep in mind that "Perl-compatible regular expressions" are really "almost-but-not-quite-Perl-compatible regular expressions".
(The fact that different languages all using the pcre library are gonna have compatible regular expressions among each other is added irony.)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Why aren't perl regular expressions really regular expressions?
by LanX (Saint) on Mar 17, 2015 at 20:35 UTC | |
|
Re^4: Why aren't perl regular expressions really regular expressions?
by Dumu (Monk) on Mar 18, 2015 at 10:32 UTC |