From 199d472203403812523ec72707c99e2dd1c5e6d1 Mon Sep 17 00:00:00 2001 From: Brady McDonough Date: Thu, 7 Jan 2021 14:19:01 -0700 Subject: [PATCH] Added (port-rewind) in a module. We don't need ' in #:export lists --- tk/listlogic.scm | 6 +++--- tk/ports.scm | 7 +++++++ 2 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 tk/ports.scm diff --git a/tk/listlogic.scm b/tk/listlogic.scm index 8fdd602..0f2fce8 100644 --- a/tk/listlogic.scm +++ b/tk/listlogic.scm @@ -1,7 +1,7 @@ (define-module (tk listlogic) - #:export ('flatten - 'lp& - 'l& + #:export (flatten + lp& + l& ) #:duplicates (warn-override-core warn )) diff --git a/tk/ports.scm b/tk/ports.scm new file mode 100644 index 0000000..a6e82ee --- /dev/null +++ b/tk/ports.scm @@ -0,0 +1,7 @@ +(define-module (tk ports) + #:export (port-rewind!) + ) + +(define (port-rewind! port chars n) + (receive (rw rest) (split-at! chars n) + (for-each (lambda (c) (unget-char port c)) rw) rest))