aboutsummaryrefslogtreecommitdiff
path: root/module/vulgar/info.scm
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-06-12 21:09:35 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2022-06-13 04:11:35 +0200
commit73a4bfc3d8e9bb5365e33a11a6ad3b8340d5195b (patch)
treee52324edc63a240e5c0b88081c325f789168a4c5 /module/vulgar/info.scm
parentDocument timespec and zic. (diff)
downloadcalp-73a4bfc3d8e9bb5365e33a11a6ad3b8340d5195b.tar.gz
calp-73a4bfc3d8e9bb5365e33a11a6ad3b8340d5195b.tar.xz
Remove custom let*.
While it was nice, the most important part was the multi-valued let from srfi-71 (which is implemented in srfi-71)). The minor pattern matching structures could often be replaced with car+cdr, or a propper match.
Diffstat (limited to 'module/vulgar/info.scm')
-rw-r--r--module/vulgar/info.scm5
1 files changed, 3 insertions, 2 deletions
diff --git a/module/vulgar/info.scm b/module/vulgar/info.scm
index 963e20c8..0f55c942 100644
--- a/module/vulgar/info.scm
+++ b/module/vulgar/info.scm
@@ -1,10 +1,11 @@
(define-module (vulgar info)
- :use-module (hnh util))
+ :use-module ((srfi srfi-1) :select (car+cdr))
+ :use-module (srfi srfi-71))
;; Sort-of backwards subprocess call since we want the current terminal to be
;; inherited by stty
(define-public (get-terminal-size)
- (let* (((rpipe . wpipe) (pipe)))
+ (let ((rpipe wpipe (car+cdr (pipe))))
(system (format #f "stty size > /proc/~s/fd/~s"
(getpid) (port->fdes wpipe)))
(values (read rpipe)