At 12:04 AM 12/15/2001 -0500, [EMAIL PROTECTED] wrote: >Can we start some dialogue about stream filters? >What form they take, are we talking regular expressions, etc.
Yes, we can. Here's what I'm thinking of. *) Filehandles get treated like arrays. Filters (which will be plain coderefs) can be push/pop/shift/unshift/spliced onto them. *) Filters get passed a PMC and an int. The int is a function number (1=read, 2=write, 3=seek, 4=tell, 5=control, or something like that) and the PMC represents the source data. They return a mutated PMC that's passed on to the next filter. I'd like the whole filter chain to run in its own interpreter, but that means the filters can't ultimately return objects and things like that, which is sort of bad. Dan --------------------------------------"it's like this"------------------- Dan Sugalski even samurai [EMAIL PROTECTED] have teddy bears and even teddy bears get drunk