From: Hoehle, Joerg-C. <Joe...@t-...> - 2003-01-23 16:01:29
|
Hi, I just realized that these two functions - which have been in CLISP for = a decade - are missing from impnotes.html. They come in very handy when writing custom streams. MAKE-BUFFERED-INPUT-STREAM can make a stream take input from a = function, lazily! MAKE-BUFFERED-OUTPUT-STREAM does line buffering on output. This = enhances tiny write() pretty much. I prefer to report this here instead of filing a bug-report, so people = can start using them! For example, MAKE-BUFFERED-INPUT-STREAM might work nicely together with = non-blocking or single calls to read() on sockets and pipes(might need = enhancement to return ls_wait status to the listen function). A nice extension to the output behaviour would be to allow any kind of = buffering, e.g. in 4KB chunks. Both are limited to character streams. But see the cookbook on how to = do arbitrary 8bit output using character streams. http://cl-cookbook.sourceforge.net/io.html#faith Regards, J=F6rg H=F6hle. |