[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] branch main updated: Fix bug in srfi-111 box printer
From: |
Daniel Llorens |
Subject: |
[Guile-commits] branch main updated: Fix bug in srfi-111 box printer |
Date: |
Thu, 16 Jan 2025 09:48:43 -0500 |
This is an automated email from the git hooks/post-receive script.
lloda pushed a commit to branch main
in repository guile.
The following commit(s) were added to refs/heads/main by this push:
new bf3c632b8 Fix bug in srfi-111 box printer
bf3c632b8 is described below
commit bf3c632b8227f4fa44b6858e4ec0f6cbdb4bf1c6
Author: Daniel Llorens <lloda@sarc.name>
AuthorDate: Thu Jan 16 15:46:05 2025 +0100
Fix bug in srfi-111 box printer
* module/srfi/srfi-111.scm: Add missing port.
* test-suite/tests/srfi-111.test: Test.
---
module/srfi/srfi-111.scm | 2 +-
test-suite/tests/srfi-111.test | 6 +++++-
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/module/srfi/srfi-111.scm b/module/srfi/srfi-111.scm
index 3d3cd896b..2db34ffc4 100644
--- a/module/srfi/srfi-111.scm
+++ b/module/srfi/srfi-111.scm
@@ -32,6 +32,6 @@
(lambda (box port)
(display "#<box " port)
(display (number->string (object-address box) 16) port)
- (display " value: ")
+ (display " value: " port)
(write (unbox box) port)
(display ">" port)))
diff --git a/test-suite/tests/srfi-111.test b/test-suite/tests/srfi-111.test
index e2d76c6d5..8d56ea907 100644
--- a/test-suite/tests/srfi-111.test
+++ b/test-suite/tests/srfi-111.test
@@ -62,4 +62,8 @@
(not (equal? box1 box2))
;; Guile extension, not guaranteed by SRFI-111.
(begin (set-box! box2 (string #\f #\o #\o))
- (equal? box1 box2)))))))
+ (equal? box1 box2))))))
+
+ (pass-if "box printer"
+ (integer? (string-contains (call-with-output-string (lambda (o) (display
(box 1) o)))
+ "value: 1"))))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Guile-commits] branch main updated: Fix bug in srfi-111 box printer,
Daniel Llorens <=