* [PATCH] doc: Use UNLESS instead of single-armed IF.
@ 2020-06-14 13:37 Ricardo Wurmus
0 siblings, 0 replies; only message in thread
From: Ricardo Wurmus @ 2020-06-14 13:37 UTC (permalink / raw)
To: guile-devel
* doc/ref/posix.texi (Pipes): Use UNLESS in OPEN-OUTPUT-PIPE example.
---
doc/ref/posix.texi | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/doc/ref/posix.texi b/doc/ref/posix.texi
index b2be9d707..ce753b864 100644
--- a/doc/ref/posix.texi
+++ b/doc/ref/posix.texi
@@ -2335,8 +2335,8 @@ Equivalent to @code{open-pipe} with mode @code{OPEN_WRITE}.
@lisp
(let ((port (open-output-pipe "lpr")))
(display "Something for the line printer.\n" port)
- (if (not (eqv? 0 (status:exit-val (close-pipe port))))
- (error "Cannot print")))
+ (unless (eqv? 0 (status:exit-val (close-pipe port))))
+ (error "Cannot print"))
@end lisp
@end deffn
--
2.26.2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2020-06-14 13:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-14 13:37 [PATCH] doc: Use UNLESS instead of single-armed IF Ricardo Wurmus
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).