> I've been working at updating the various synopses on dev.perl.org.
> In particular, you folks might like to know that the regex synopsis at:
>
> http://dev.perl.org/perl6/synopsis/S05.html
>
> is no longer two years out of date :-)
>
> Larry
ok, cool, I'm beginning to understand perl6 patterns a bit better.
Just a tiny request though (and I seem to remember this being discussed) -
I wish that there was an easy syntax to turn regexes inside out as it were,
to be able to generate text strings given a certain rule, especially at border cases
- something like:
rule nonquote { <[^\n"]>+ }
rule slashchar { \\ <[^\n]> }
m:gen('1000')/(" ( <nonquote> | <slashchar> )* ")/
generating
""
"x"
"\x"
"\\x"
....
ie - 1000 matching strings for the particular rule.
If this isn't possible in the core itself, I'd be interested in seeing how it would
be possible to program outside it as a user defined modifier.
Ed
(
ps - is there a 'metaphor translation guide' between perl5 and perl6 regex?
ex - what does ?: translate to? is '?>' subsumed by backtracking control
and if so, how?
)