docs for revised system error message completed

(manually adapted)

(cherry picked from commit 6768136144)
This commit is contained in:
Matthias Felleisen 2012-07-20 11:56:16 -04:00 committed by Ryan Culpepper
parent d0c76a84a7
commit 1d64b3a94f
3 changed files with 19 additions and 4 deletions

View File

@ -6,7 +6,10 @@
system
system*
system/exit-code
system*/exit-code)
system*/exit-code
string-no-nuls?
bytes-no-nuls?)
(require "private/streams.rkt")
@ -82,9 +85,6 @@
s)))])
args)
;; MF: fxing a somewhat awkward looking error message. Comment for Matthew in case he wants to improve on it.
(provide string-no-nuls? bytes-no-nuls?)
(define (check-command who str)
(unless (or (string-no-nuls? str)
(bytes-no-nuls? str))

View File

@ -482,3 +482,17 @@ returned list is @racket[#f].}
Like @racket[process*], but with the port handling of
@racket[process/ports].}
@; ----------------------------------------------------------------------
@;section{Contract Auxiliaries}
@;note-lib[racket/system]
The contracts of @racket[system] and related functions may signal a
contract error with references to the following functions.
@defproc[(string-no-nuls? [x any/c]) boolean?]{
Ensures that @racket[x] is a string and does not contain @racket["\0"].}
@defproc[(bytes-no-nuls? [x any/c]) boolean?]{
Ensures that @racket[x] is a byte-string and does not contain @racket["\0"].}

View File

@ -77,6 +77,7 @@ racket/sandbox: added sandbox-propagate-exceptions; added
racket/cmdline: add #:ps for command-line
slideshow/start: run a `slideshow' or `main' submodule, if any
scribble/eval: added eval:result and eval:results
racket/system: improved error messages by replacing memv expressions with string-no-nuls? and bytes-no-nuls?
Version 5.2.1, January 2012
Changed I/O scheduling to use epoll()/kqueue() when available