loris has asked for the wisdom of the Perl Monks concerning the following question:
Monks,
What would the best way of testing whether two regexes are equivalent? In particular, I am interested in seeing whether some apparently complex regex is actually equivalent to
.*I could obviously construct a set of strings which are somehow typical and see whether both regexes selected the same set, but that would demonstrate only rather limited equivalence and seems a bit of lame approach.
Thanks,
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Testing regex equivalence
by Corion (Patriarch) on Feb 21, 2006 at 12:57 UTC | |
by loris (Hermit) on Feb 21, 2006 at 13:13 UTC | |
by Corion (Patriarch) on Feb 21, 2006 at 13:19 UTC | |
Re: Testing regex equivalence
by blokhead (Monsignor) on Feb 21, 2006 at 17:25 UTC | |
Re: Testing regex equivalence
by aquarium (Curate) on Feb 21, 2006 at 13:07 UTC | |
by grinder (Bishop) on Feb 21, 2006 at 15:25 UTC | |
Re: Testing regex equivalence
by mickeyn (Priest) on Feb 21, 2006 at 12:45 UTC | |
by loris (Hermit) on Feb 21, 2006 at 12:50 UTC |