in reply to Regexes on Streams

Some thoughts from your questions:

Is there a robust, pure-Perl way of inspecting regular expressions for possibly infinite constructs? Anything non-extreme but involving XS?

Maybe Mark-Jason Dominus' Rx module will allow you to inspect a regular expression enough to find out about infinite constructs.

...by reading in another block from the stream and reperforming the match

I would set a sort of "timeout" value here, I guess "dataout" value would be more appropriate. ;-)

...$handle/HANDLE needn't be a File::Stream tied handle, but may be just any filehandle.

Maybe you could achieve this by pushing an PerlIO handler on the handle?

Liz