Re: multiline rex.match
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: multiline rex.match
- From: Philippe Lhoste <PhiLho@...>
- Date: 2010年12月16日 23:14:51 +0100
On 16/12/2010 18:38, Shmuel Zeigerman wrote:
Oops, my face is turning red. :)
;-) No problem, and I used the link you nicely provided, saving me a
search...
Yehuda, the manual shows we can provide "ef", execution flags, like
PCRE_MULTILINE or PCRE_DOTALL, to most methods.
The flags you referred to are in fact "cf", compilation flags. They can
be specified in the 4-th argument of rex.match as "m" and "s"
respectively. They can also be specified directly in (parts of) the
pattern as (?m) or (?s).
OK. I just downloaded the lib and opened the manual, but found this
topic on flags a bit obscure (from a quick scan at least).
At least the fact they are listed (in match() ref. for example) as
numbers with bitwise OR... A quick look at the tests didn't help either.
I found also the references to Oniguruma a bit obscure, until I took the
time to look for it (that's a Ruby regex library - the name seems to
mean demon-car 鬼車, not sure to see how it relates to regexes).
--
Philippe Lhoste
-- (near) Paris -- France
-- http://Phi.Lho.free.fr
-- -- -- -- -- -- -- -- -- -- -- -- -- --