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)]}