bsb has asked for the wisdom of the Perl Monks concerning the following question:
Is there a module which can generate strings
that satisfy a certain regular expression?
Anything else I should look at?
My only lead isqr/^ab?(c|d)$/ => qw/ac abc ad abd/;
which I got from GraphViz::Regex, which parses the output to graph it.$ perl -e 'use re "debug"; /^ab?(c|d)$/'
Anything else I should look at?
Obviously there's issues about infinite languages, what does '.' do, unanchored expressions, perl's (?..) features. But let's be "Can Do" people :)
Brad
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Regexp generating strings?
by larsen (Parson) on Aug 18, 2003 at 09:32 UTC | |
by bsb (Priest) on Aug 20, 2003 at 00:20 UTC | |
Re: Regexp generating strings?
by gjb (Vicar) on Aug 18, 2003 at 09:45 UTC | |
Re: Regexp generating strings?
by Abigail-II (Bishop) on Aug 18, 2003 at 09:34 UTC | |
by Corion (Patriarch) on Aug 18, 2003 at 10:48 UTC | |
by bsb (Priest) on Aug 20, 2003 at 00:53 UTC | |
Re: Regexp generating strings?
by CombatSquirrel (Hermit) on Aug 18, 2003 at 16:17 UTC | |
Re: Regexp generating strings?
by bsb (Priest) on Aug 27, 2003 at 08:53 UTC |
Back to
Seekers of Perl Wisdom