X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=tests%2F11_match_ints.ml;h=c9ffd1aa7954bed23639ccfaa59b3b2e5008bd56;hb=80fd187cbf946133e98ca32d351c33132ce3ea47;hp=e8f54b99c439c0f722f43820a4e4f654cae58af2;hpb=4c5e16867283de5cd28ff7d3135b110cad78eac5;p=ocaml-bitstring.git diff --git a/tests/11_match_ints.ml b/tests/11_match_ints.ml index e8f54b9..c9ffd1a 100644 --- a/tests/11_match_ints.ml +++ b/tests/11_match_ints.ml @@ -21,12 +21,12 @@ let () = Random.int64 (Int64.sub (Int64.shift_left 1L bitlen) 1L)) (range 0 (len-1)) in - let bits = Bitmatch.Buffer.create () in + let bits = Bitstring.Buffer.create () in List.iter (fun i -> - Bitmatch.construct_int64_be_unsigned bits i bitlen + Bitstring.construct_int64_be_unsigned bits i bitlen (Failure "constructing string")) expected; - let bits = Bitmatch.Buffer.contents bits in + let bits = Bitstring.Buffer.contents bits in (* Now read the bitstring as integers. * In each case check the result against what we generated ('expected'). @@ -35,7 +35,7 @@ let () = let rec loop bits = bitmatch bits with | { i : bitlen; rest : -1 : bitstring } - when Bitmatch.bitstring_length rest = 0 -> [i] + when Bitstring.bitstring_length rest = 0 -> [i] | { i : bitlen; rest : -1 : bitstring } -> i :: loop rest | { _ } -> failwith (sprintf "loop failed with len = %d, bitlen = %d"