From 90040aac2b57d18fc0e2ce650db685ce246c72ed Mon Sep 17 00:00:00 2001 From: Eli Barzilay Date: Mon, 25 May 2009 02:56:24 +0000 Subject: [PATCH] another typo from PR10258 (less than or equal to the string length) svn: r14976 --- collects/scribblings/reference/bytes.scrbl | 14 +++++++------- collects/scribblings/reference/strings.scrbl | 11 ++++++----- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/collects/scribblings/reference/bytes.scrbl b/collects/scribblings/reference/bytes.scrbl index f3d9465309..439c21cc3f 100644 --- a/collects/scribblings/reference/bytes.scrbl +++ b/collects/scribblings/reference/bytes.scrbl @@ -90,13 +90,13 @@ positions are initialized with the given @scheme[b]s. @defproc[(subbytes [bstr bytes?] [start exact-nonnegative-integer?] - [end exact-nonnegative-integer? (bytes-length str)]) bytes?]{ - Returns a new mutable byte string that is @scheme[(- end start)] - bytes long, and that contains the same bytes - as @scheme[bstr] from @scheme[start] inclusive to @scheme[end] exclusive. The - @scheme[start] and @scheme[end] arguments must be less than the length of - @scheme[bstr], and @scheme[end] must be greater than or equal to @scheme[start], - otherwise the @exnraise[exn:fail:contract]. + [end exact-nonnegative-integer? (bytes-length str)]) bytes?]{ Returns + a new mutable byte string that is @scheme[(- end start)] bytes long, + and that contains the same bytes as @scheme[bstr] from @scheme[start] + inclusive to @scheme[end] exclusive. The @scheme[start] and + @scheme[end] arguments must be less than or equal to the length of + @scheme[bstr], and @scheme[end] must be greater than or equal to + @scheme[start], otherwise the @exnraise[exn:fail:contract]. @mz-examples[(subbytes #"Apple" 1 3) (subbytes #"Apple" 1)]} diff --git a/collects/scribblings/reference/strings.scrbl b/collects/scribblings/reference/strings.scrbl index de46ec1daf..020caddb3c 100644 --- a/collects/scribblings/reference/strings.scrbl +++ b/collects/scribblings/reference/strings.scrbl @@ -85,11 +85,12 @@ Returns an immutable string with the same content as @defproc[(substring [str string?] [start exact-nonnegative-integer?] [end exact-nonnegative-integer? (string-length str)]) string?]{ Returns a new mutable string that is @scheme[(- end start)] - characters long, and that contains the same characters - as @scheme[str] from @scheme[start] inclusive to @scheme[end] exclusive. The - @scheme[start] and @scheme[end] arguments must be less than the length of - @scheme[str], and @scheme[end] must be greater than or equal to @scheme[start], - otherwise the @exnraise[exn:fail:contract]. + characters long, and that contains the same characters as + @scheme[str] from @scheme[start] inclusive to @scheme[end] exclusive. + The @scheme[start] and @scheme[end] arguments must be less than or + equal to the length of @scheme[str], and @scheme[end] must be greater + than or equal to @scheme[start], otherwise the + @exnraise[exn:fail:contract]. @mz-examples[(substring "Apple" 1 3) (substring "Apple" 1)]}