From fabb5d7965c957715120747b693fdd6cab1f1de5 Mon Sep 17 00:00:00 2001 From: Spiros Eliopoulos Date: Mon, 5 Jul 2021 16:30:04 -0400 Subject: [PATCH] pr47: update documentation --- lib/bigstringaf.mli | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/lib/bigstringaf.mli b/lib/bigstringaf.mli index 7f6c34b..bbf02a8 100644 --- a/lib/bigstringaf.mli +++ b/lib/bigstringaf.mli @@ -164,11 +164,11 @@ val blit_to_bytes : t -> src_off:int -> Bytes.t -> dst_off:int -> len:int -> uni val memcmp : t -> int -> t -> int -> int -> int val memcmp_string : t -> int -> string -> int -> int -> int -(** {4 [memchr]} +(** {3 [memchr]} + + Search for a byte using [memchr], returning [-1] if the byte is not found. + Performing bounds checking before the C call. *) - Search for a byte in a bigstring using [memchr]. Similar to [unsafe_memchr] - but this performs bounds checks. - *) val memchr : t -> int -> char -> int -> int (** {2 Memory-unsafe Operations} @@ -274,8 +274,9 @@ val unsafe_blit_to_bytes : t -> src_off:int -> Bytes.t -> dst_off:int -> len:int val unsafe_memcmp : t -> int -> t -> int -> int -> int val unsafe_memcmp_string : t -> int -> string -> int -> int -> int -(** {4 [memchr]} +(** {3 [memchr]} + + Search for a byte using [memchr], returning [-1] if the byte is not found. + It does not check bounds before the C call. *) - Search for a byte in a bigstring using [memchr]. - *) val unsafe_memchr : t -> int -> char -> int -> int