in reply to Compare two regex patterns

Before writing a UI that accepts regular expressions, you should review the (?{code}) and (??{code}) patterns in perlre. You will want to remember this curious statement...
use re 'eval'; # Open Pandora's box
and make sure it is NOT being used*... otherwise your users may find some remarkably interesting patterns to type in.

 

* (at least, not in the same section of code, and not without turning on taint.)