Fix bootstrap error
parent
50e3d36d8e
commit
8bb7aafee5
|
@ -16,7 +16,5 @@ HELP: <duplex-stream>
|
|||
{ $values { "in" "an input stream" } { "out" "an output stream" } { "stream" " a duplex stream" } }
|
||||
{ $description "Creates a duplex stream. Writing to a duplex stream will write to " { $snippet "out" } ", and reading from a duplex stream will read from " { $snippet "in" } ". Closing a duplex stream closes both the input and output streams." } ;
|
||||
|
||||
HELP: check-closed
|
||||
{ $values { "stream" "a duplex stream" } }
|
||||
{ $description "Throws a " { $link check-closed } " error if the stream has already been closed." }
|
||||
HELP: stream-closed-twice
|
||||
{ $error-description "This error is thrown when performing an I/O operation on a " { $link duplex-stream } " which has been closed with " { $link dispose } "." } ;
|
||||
|
|
|
@ -11,10 +11,10 @@ TUPLE: duplex-stream in out closed ;
|
|||
: <duplex-stream> ( in out -- stream )
|
||||
f duplex-stream construct-boa ;
|
||||
|
||||
<PRIVATE
|
||||
|
||||
ERROR: stream-closed-twice ;
|
||||
|
||||
<PRIVATE
|
||||
|
||||
: check-closed ( stream -- stream )
|
||||
dup closed>> [ stream-closed-twice ] when ; inline
|
||||
|
||||
|
|
Loading…
Reference in New Issue