Skip to content
Snippets Groups Projects
Commit f303e1ec authored by toy's avatar toy
Browse files

Rudi Schlatte noted that

    The Hyperspec says that the default for end is nil, but:

    * (write-string "bla" *standard-output* :start 0 :end nil)

    Type-error in KERNEL::OBJECT-NOT-FIXNUM-ERROR-HANDLER:
       NIL is not of type FIXNUM

Fix this and make the default for :END be NIL.  (Hmm, I suppose we
don't really have to default to NIL since NIL means the end of the
string anyway, but we should at least accept NIL as a valid :END
value.  I didn't do that.)
parent 5dd57043
No related branches found
No related tags found
No related merge requests found
......@@ -5,7 +5,7 @@
;;; Carnegie Mellon University, and has been placed in the public domain.
;;;
(ext:file-comment
"$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/stream.lisp,v 1.49 2002/02/04 17:22:15 toy Exp $")
"$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/stream.lisp,v 1.50 2002/06/10 22:41:24 toy Exp $")
;;;
;;; **********************************************************************
;;;
......@@ -566,9 +566,9 @@
(stream-fresh-line stream))))
(defun write-string (string &optional (stream *standard-output*)
&key (start 0) (end (length (the vector string))))
&key (start 0) end)
"Outputs the String to the given Stream."
(write-string* string stream start end))
(write-string* string stream start (or end (length (the vector string)))))
(defun write-string* (string &optional (stream *standard-output*)
(start 0) (end (length (the vector string))))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment