On Tue 05 Sep, David Corbin wrote:
> Nathan Wiger wrote:
> > 
> > But, how about a new ?m operator?
> > 
> >    /(?m<<|[).*?(?M>>|])/;
> > 
> 
> Let's combine yor operator with my example from above where everything
> inside the (?m) or the ?(M)
> fits the syntax of a RE.  
> 
>       /(?m(<<)|\[).*?(?M(>>)|(\]))
> 
> > Then the ?M matches pairs with the previous ?m, if there was one that
> > was matched. The | character separates or'ed sets consistent with other
> > regex patterns.

There already is a (?m

The whole (?x set of thingies is getting complicated...  The list of what is
used at present (and in current suggestions is:

Current Use in perl5

(?#     comment
(?imsx  flags
(?-imsx flags
(?:     subexpression without bracket capture
(?=     zero-width positive look ahead
(?!     zero width negative look ahead
(?<=    zero-width positve look behind
(?<!    zero width negative look behind
(?{code}        Execute code
(??{code} Execute code and use result as pattern
(?>     Independant subexpression
(?(condition)yes-pattern
(?(condition)yes-pattern|no-pattern

Suggested in RFCs either current or in development

(?$foo= suggested for assignment (RFC 112)
(?%foo= suggested for hash assignment (RFC 150?)

(?@foo  suggested list expansion (?:$foo[0] | $foo[1] | ...) ? (RFC 166)
(?Q@foo) Quote each item of lists (RFC 166)
(?^pattern) matches anything that does not match pattern 
        (RFC 166 but will be somewhere else on next rewrite [1])
(?F             Failure tokens (RFC in development by me [1])
(?r),(?f)       Suggested in Direction Control RFC 1
(?&             Boolean regexes (RFC in development [1])
(?*{code})      Execute code with pass/fail result (RFC in development [1])

[1] these will all be in an RFC which will probably be out in a day or so.

Unused (? sequences

a,b,c,d,e, ,g,h, ,j,k,l, ,n,o,p,q, , ,t,u,v,w,x,y,z
A,B,C,D,E, ,G,H,I,J,K,L,M,N,O,P, ,R,S,T,U,V,W,X,Y,Z
0,1,2,3,4,5,6,7,8,9
`_,."+[];'~)

(if I have forgotten any do tell and I will try and keep this list up to
date.

Richard


-- 

[EMAIL PROTECTED]

Reply via email to