Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^2: A regex that only matches at offset that are multiples of a given N?

by 7stud (Deacon)
on Feb 14, 2013 at 18:57 UTC ( #1018767=note: print w/ replies, xml ) Need Help??


in reply to Re: A regex that only matches at offset that are multiples of a given N?
in thread A regex that only matches at offset that are multiples of a given N?

In this regex:

fred (? (?{ pos % 4 != 0 }) (?!) ) (....)

What does this construct do:

(?stuff)

I can't find anything about that in perlre.

Edit: Ah, the boolean test finally clued me in:

(?(condition)yes-pattern)


Comment on Re^2: A regex that only matches at offset that are multiples of a given N?
Select or Download Code
Replies are listed 'Best First'.
Re^3: A regex that only matches at offset that are multiples of a given N?
by smls (Friar) on Feb 15, 2013 at 12:27 UTC
    I can't find anything about that in perlre.

    perlre is not exactly optimized for quickly finding out the meaning of a specific regex construct.

    Use perlreref for that.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1018767]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (11)
As of 2015-07-31 18:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (280 votes), past polls