Contents

  Icon

Flow control and code execution

Anchors

Basic metacharacters

Character classes

Comments

Control and code

Grouping

Look around

Mode modifiers

Quantifiers

Specific characters

Perl allows you to run code and control execution flow inside regular expressions. By default this option is disabled in RegExhibit. If you think you know what you are doing, you can enabled it. But be aware. It is terribly easy to do something you might regret.

RegExhibit disallows you to “print” (or any of its variants) to STDOUT. You can use “warn”, but that will only cause RegExhibit to think the regular expression is invalid.

To keep in the spirit of Programming Perl: here be dragons

 

 

Item

 

Meaning:

 
 

(?{…})

 

Execute embedded Perl code.

 
 

(??{…})

 

Match regular expression from embedded Perl code.

 
 

(?(…)…)

 

Match with if-then pattern.

 
 

(?(…)…|…)

 

Match with if-then-else pattern.

 
 

In the table “…” stands for any one or more characters.