From b50ffc6da0b10938260e4fa97881b9e9039df403 Mon Sep 17 00:00:00 2001 From: Joe Groff Date: Mon, 28 Nov 2011 20:36:34 -0800 Subject: [PATCH] io: implement stream protocols on f Fixes deployed applications that write to output-stream --- core/io/io.factor | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/core/io/io.factor b/core/io/io.factor index b2485a6141..d4d54b8852 100644 --- a/core/io/io.factor +++ b/core/io/io.factor @@ -248,3 +248,15 @@ M: output-stream stream-nl CHAR: \n swap stream-write1 ; inline M: output-stream stream-seekable? drop f ; inline M: output-stream stream-length drop f ; inline +M: f stream-read1 drop f ; inline +M: f stream-read-unsafe 3drop 0 ; inline +M: f stream-read-until 2drop f f ; inline +M: f stream-read-partial-unsafe 3drop 0 ; inline +M: f stream-readln drop f ; inline +M: f stream-contents drop f ; inline + +M: f stream-write1 2drop ; inline +M: f stream-write 2drop ; inline +M: f stream-flush drop ; inline +M: f stream-nl drop ; inline +