From e1e522be9c6f0fa8fe9c03d26b80df5f3472fc11 Mon Sep 17 00:00:00 2001 From: Joe Marshall Date: Wed, 24 Mar 2010 09:14:10 -0700 Subject: [PATCH] New input port operation 'INPUT-LINE. --- src/runtime/input.scm | 5 +++++ src/runtime/runtime.pkg | 1 + 2 files changed, 6 insertions(+) diff --git a/src/runtime/input.scm b/src/runtime/input.scm index d3d55afff..fde4fb73a 100644 --- a/src/runtime/input.scm +++ b/src/runtime/input.scm @@ -131,6 +131,11 @@ USA. (let ((eof? (port/operation port 'EOF?))) (and eof? (eof? port)))) + +(define (input-port/line port) + (let ((operation (port/operation port 'INPUT-LINE))) + (and operation + (operation port)))) ;;;; High level diff --git a/src/runtime/runtime.pkg b/src/runtime/runtime.pkg index 28fb7de1a..e5525005d 100644 --- a/src/runtime/runtime.pkg +++ b/src/runtime/runtime.pkg @@ -2146,6 +2146,7 @@ USA. input-port/%read-char input-port/%peek-char input-port/char-ready? + input-port/line input-port/discard-chars input-port/eof? input-port/peek-char -- 2.25.1