On 1/24/06, Adriano Allora <[EMAIL PROTECTED]> wrote:

> and the pattern results in stdout as this:
> ^(?:(?-xism:ara\w+))[^A-Z]*((?-xism:[A-Z]+))[^A-Z]*(?!arabo)
> It's quite strange: the first and second element have got a pair of
> brackets more and I don't understand what -xism does mean.

It's still your pattern. Perl has re-written it a little, now that
it's one big string. Since parts compiled with qr{} didn't have flags
like i (case-insensitive), and also in order to show correct
precedence, those parts are marked with one or another form of the
(?:) non-memory parentheses. So the part that looks like -xism to you
looks like a piece of (?-xism:FOO) to me, where FOO is the affected
part of the pattern. Look for the item on (?imsx-imsx:pattern) in the
perlre manpage.

In this case, your pattern would look roughly like this, I think, if
those parts weren't marked:

    ^ara\w+[^A-Z]*([A-Z]+)[^A-Z]*(?!arabo)

Does that look roughly like the pattern that you were aiming for? Hope
this helps!

--Tom Phoenix
Stonehenge Perl Training

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to