X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=contrib%2Fsb-simple-streams%2Fimpl.lisp;h=a8adfa0b2a64098b5acd948d59fa6c977fac9ffc;hb=32c8edbd49ca77907154987e28e8d3f81f61dabc;hp=f85edeb0f12d2c038bec5d5b7acbb2034a248f3d;hpb=cc9a73604f696b6e69842a95b1e11f40f8cdd7bf;p=sbcl.git diff --git a/contrib/sb-simple-streams/impl.lisp b/contrib/sb-simple-streams/impl.lisp index f85edeb..a8adfa0 100644 --- a/contrib/sb-simple-streams/impl.lisp +++ b/contrib/sb-simple-streams/impl.lisp @@ -292,7 +292,8 @@ (if (not (or (eql width 1) (null width))) (funcall-stm-handler j-listen (sm melded-stream stream)) (or (< (sm buffpos stream) (sm buffer-ptr stream)) - (when (>= (sm mode stream) 0) ;; device-connected @@ single-channel + (when (or (not (any-stream-instance-flags stream :dual :string)) + (>= (sm mode stream) 0)) ;; device-connected @@ single-channel (let ((lcrs (sm last-char-read-size stream))) (unwind-protect (progn @@ -952,6 +953,8 @@ (etypecase stream (simple-stream (%peek-char stream peek-type eof-error-p eof-value recursive-p)) + ;; FIXME: Broken on ECHO-STREAM (cf internal implementation?) -- + ;; CSR, 2004-01-19 (ansi-stream (let ((char (%ansi-stream-read-char stream eof-error-p eof-value t))) (cond ((eq char eof-value) char) @@ -966,7 +969,7 @@ (do ((char char (%ansi-stream-read-char stream eof-error-p eof-value t))) ((or (eq char eof-value) - (not (sb-int:whitespace-char-p char))) + (not (sb-impl::whitespacep char))) (unless (eq char eof-value) (%ansi-stream-unread-char char stream)) char))) @@ -986,7 +989,7 @@ ((eq peek-type t) (do ((char (sb-gray:stream-read-char stream) (sb-gray:stream-read-char stream))) - ((or (eq char :eof) (not (sb-int:whitespace-char-p char))) + ((or (eq char :eof) (not (sb-impl::whitespacep char))) (cond ((eq char :eof) (sb-impl::eof-or-lose stream eof-error-p eof-value)) (t @@ -1304,37 +1307,3 @@ t) (t (sb-impl::fd-stream-pathname stream)))))) - -;;; bugfix - -;;; TODO: Rudi 2003-01-12: What is this for? Incorporate into sbcl or -;;; remove it. -#+nil -(defun cl::stream-misc-dispatch (stream operation &optional arg1 arg2) - (declare (type fundamental-stream stream) ;; this is a lie - (ignore arg2)) - (case operation - (:listen - (ext:stream-listen stream)) - (:unread - (ext:stream-unread-char stream arg1)) - (:close - (close stream)) - (:clear-input - (ext:stream-clear-input stream)) - (:force-output - (ext:stream-force-output stream)) - (:finish-output - (ext:stream-finish-output stream)) - (:element-type - (stream-element-type stream)) - (:interactive-p - (interactive-stream-p stream)) - (:line-length - (ext:stream-line-length stream)) - (:charpos - (ext:stream-line-column stream)) - (:file-length - (file-length stream)) - (:file-position - (file-position stream arg1))))