integrated Raymond Wiker's patches to port RUN-PROGRAM from CMU CL and
[sbcl.git] / src / pcl / gray-streams-class.lisp
1 ;;;; class definitions for the SBCL Gray streams implementation, based on the
2 ;;;; CMU CL Gray streams implementation, based on the stream-definition-by-user
3 ;;;; proposal by David N. Gray
4
5 ;;;; This software is part of the SBCL system. See the README file for
6 ;;;; more information.
7
8 ;;;; This software is in the public domain and is provided with absolutely no
9 ;;;; warranty. See the COPYING and CREDITS files for more information.
10
11 (in-package "SB-GRAY")
12
13 (sb-int:file-comment
14   "$Header$")
15 \f
16 ;;; Bootstrap the FUNDAMENTAL-STREAM class.
17 (let ((sb-pcl::*pcl-class-boot* 'fundamental-stream))
18   (defclass fundamental-stream (standard-object stream)
19     ()
20     #+sb-doc
21     (:documentation "the base class for all CLOS streams")))
22
23 ;;; Define the stream classes.
24 (defclass fundamental-input-stream (fundamental-stream) nil)
25
26 (defclass fundamental-output-stream (fundamental-stream) nil)
27
28 (defclass fundamental-character-stream (fundamental-stream) nil)
29
30 (defclass fundamental-binary-stream (fundamental-stream) nil)
31
32 (defclass fundamental-character-input-stream
33     (fundamental-input-stream fundamental-character-stream) nil)
34
35 (defclass fundamental-character-output-stream
36     (fundamental-output-stream fundamental-character-stream) nil)
37
38 (defclass fundamental-binary-input-stream
39     (fundamental-input-stream fundamental-binary-stream) nil)
40
41 (defclass fundamental-binary-output-stream
42     (fundamental-output-stream fundamental-binary-stream) nil)
43 \f
44 ;;; example character input and output streams
45
46 (defclass character-output-stream (fundamental-character-output-stream)
47   ((lisp-stream :initarg :lisp-stream
48                 :accessor character-output-stream-lisp-stream)))
49
50 (defclass character-input-stream (fundamental-character-input-stream)
51   ((lisp-stream :initarg :lisp-stream
52                 :accessor character-input-stream-lisp-stream)))