On Fri, Aug 25, 2000 at 03:46:59PM -0400, Eric Roode wrote:
> Nat wrote:
> >5.6's regular expressions have (??{ ... }) to permit recursion and
> >$^R to maintain state through the parsing.
>
> In another thread, Tomc wrote:
> >[...] Likewise the @+ and @- stuff.
>
> Okay, I'm throwing my ignorance out for the whole world to see. WTF??
>
> Sure, I'm not in the loop, as certainly gnat and tomc are, but ...
> I haven't heard of these features, and can't begin to guess what they
> mean. I just spent an hour or two cruising the perl web site, and
> nothing about them did I find. Most especially, no mention of any of
> them is made in the What's New in 5.6.0, What's new in 5.005, or
> What's New in 5.004 articles.
perl56delta says, at the end of a list of experimental things:
=item The regular expression constructs C<(?{ code })> and C<(??{ code })>
perlvar and perlretut both talk about @+/@-.
All in all, though, you're right that neither set of features is particularly
well-known/used outside of p5p followers. At least from what I've seen.
Virtually every person I've worked with since 5.6 came out has been surprised
and amazed at the REx eval stuff.
Using the REx eval features, it is possible to do "brace matching", but it's
not the world's most beautiful solution. I do like this RFC, but nagging at
the back of my mind is that it's not general enough. I can't quite figure out
how to abstract it more, though.
[insert idle wish for Ilya's presence here]
-dlc