--- Brent Dax <[EMAIL PROTECTED]> wrote:
> Tim Bunce:
> # On Thu, Jan 31, 2002 at 05:15:49PM +0000, Graham Barr wrote:
> #
> # Especially as the perl6 rx engine will have to be able to
> # work directly on
> # non-trivial things like streams and generators ans suchlike.
> 
> I have a suggestion similar to the ops suggestion but more flexible:
> Regex vtables.
> 
> We'd probably need three:
> 
>       -normal text match
>       -case-folded text match
>       -generic sequence match (the stuff Larry's been talking about)

Hmm... based on what I've read in Larry's message and the unicode spec,
some of this could be spirited away into a customizable and/or chained
unicode string iterator.

For instance, it (the iterator) could return case-folded (or not)
characters, it could convert "" pairs into Ps/Pe quote pairs (for code
parsers) and remove comments (yay), and it could return locale-based
graphemes (I'm scared). Since graphemes at least will be
multi-character in some locales, I see how my objection to rx_literal
was a Bad Thing. And I expect to be able to write a grapheme-sending
unicode string iterator and plug it into a regex and have it DWIM in my
Distant $future, right?

Perhaps the backtracking mechanism should be *in* the iterator? Maybe
the iterator will be the home of some locale evil? Could we make it
handle locale character-ranges [a-o'] too? Okay, that last one's a bit
much. Still, Larry did mention that business with generalized
backtracking and bookkeeping... I can't wait for Apocalypse 5.

Is there a custom iterator syntax/convention in parrot?

I hope I don't give Larry any *new* scary ideas for the next
apocalypse. This is just for entertainment purposes, after all
</disclaimer>.

Ashley the Zealot

__________________________________________________
Do You Yahoo!?
Great stuff seeking new owners in Yahoo! Auctions! 
http://auctions.yahoo.com

Reply via email to