armedbear / abcl

Armed Bear Common Lisp <git+https://github.com/armedbear/abcl/> <--> <svn+https://abcl.org/svn> Bridge
https://abcl.org#rdfs:seeAlso<https://gitlab.common-lisp.net/abcl/abcl>
Other
288 stars 29 forks source link

Use STREAMP to determine Gray stream API availability #648

Closed yitzchak closed 8 months ago

yitzchak commented 9 months ago

Using (typep obj 'stream) effectively makes the generic function STREAMP not very useful since all streams need to subclass STREAM, which always returns T for STREAMP. This is an optional part of the Gray stream protocol. Some implementations enforce the requirement that streams must subclass STREAM, i.e. CMUCL, SBCL and CLISP. On the other hand Clasp, ECL, MKCL, Mezzano and CCL all implement the generic STREAMP and don't require that Gray streams subclass STREAM.

easye commented 8 months ago

Your reasoning about streamp makes sense to me: I certainly think it is better than the current situation. Thanks!