[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


I can't find any responses to this mail.  I wonder if some of the stream
options might be easier to access if STREAM were a class under CLOS.  

Date: Fri, 19 Dec 86 15:19 EST
 From: Kent M Pitman <KMP@STONY-BROOK.SCRC.Symbolics.COM>
Message-ID: <861219151955.2.KMP@RIO-DE-JANEIRO.SCRC.Symbolics.COM>

 From time to time, I find myself doing:


in a multi-window system in order to temporarily change my interaction
to the
same window as output has been redirected to. On the Lisp Machine (and
on many or most other implementations), *STANDARD-OUTPUT* can sometimes
contain a synonym-stream for *TERMINAL-IO* and the result of the
above is to send output to a stream which is a (circular) synonym for
The kind of lossage this results in is fairly severe because *DEBUG-IO*
is often
a synonym for *TERMINAL-IO* and if that is in turn a synonym for
then the debugger cannot run.

A couple of things would make this problem more tractable:

 SYNONYM-STREAM-P object				[Function]

 This accepts any kind of argument. If the argument is not a synonym
 stream, then NIL is returned. If the argument is a synonym stream,
 then the symbol for which the object is a synonym is returned.

 FOLLOW-SYNONYM-STREAM stream				[Function]

 This accepts a stream and returns the result of following that stream
 through any number of synonym stream indirections (including zero).

While I'm on page 329, I think we should also have the following
(or functionalities) which I have needed at other times:

 BROADCAST-STREAM-P object				[Function]
 CONCATENATED-STREAM-P stream				[Function]
 TWO-WAY-STREAM-P					[Function]

 This accepts any kind of argument. It returns T if the argument is a
 {concatenated/broadcast/two-way/...} stream and NIL if the argument is
 any other kind of stream.

 EXPAND-BROADCAST-STREAM broadcast-stream		[Function]
 EXPAND-CONCATENATED-STREAM concatenated-stream		[Function]
 EXPAND-TWO-WAY-STREAM two-way-stream			[Function]

 This accepts a {broadcast/concatenated/two-way/...} stream and returns 
 a list of the streams which were used to compose it (in an order 
 compatible with the order of arguments to the creation function).
 Note: Implementations are allowed, but not required, to return the
 same list every time. The result list should not be destructively

     ----- End Forwarded Messages -----