1 USING: io help.markup help.syntax quotations ;
5 { $class-description "Singleton class of null reader streams." } ;
8 { $class-description "Singleton class of null writer streams." } ;
10 HELP: with-null-reader
11 { $values { "quot" quotation } }
12 { $description "Calls the quotation with " { $link input-stream } " rebound to a " { $link null-reader } " which always produces EOF." } ;
14 HELP: with-null-writer
15 { $values { "quot" quotation } }
16 { $description "Calls the quotation with " { $link output-stream } " rebound to a " { $link null-writer } " which ignores all output." } ;
18 ARTICLE: "io.streams.null" "Null streams"
19 "The " { $vocab-link "io.streams.null" } " vocabulary implements a pair of streams which are useful for testing. The null reader always yields EOF and the null writer ignores all output. Conceptually, they are similar to " { $snippet "/dev/null" } " on a Unix system."
22 { $subsection null-reader }
23 { $subsection with-null-writer }
25 { $subsection null-writer }
26 { $subsection with-null-reader } ;
28 ABOUT: "io.streams.null"