Module Decompress_impl.RFC1951_inflate
module Heap : sig ... endval reverse_bits : int -> inttype ('i, 'o) t = {last : bool;hold : int;bits : int;o_off : int;o_pos : int;o_len : int;i_off : int;i_pos : int;i_len : int;write : int;state : ('i, 'o) state;window : 'o Window.t;wbits : int;wi : 'i B.t;wo : 'o B.t;
}and ('i, 'o) state = | Last| Block| Flat of ('i, 'o) k| Fixed| Dictionary of ('i, 'o) k| Inffast of Lookup.t * Lookup.t * code| Inflate of ('i, 'o) k| Switch| Finish of int| Exception of error
and ('i, 'o) res = | Cont of ('i, 'o) t| Wait of ('i, 'o) t| Flush of ('i, 'o) t| Ok of ('i, 'o) t| Error of ('i, 'o) t * error
and code = | Length| ExtLength of int| Dist of int| ExtDist of int * int| Write of int * int
val error : ('a, 'b) t -> error -> ('a, 'b) resval ok : ('a, 'b) t -> int -> ('a, 'b) resval get_byte :
ctor:
((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('b, 'd) state) ->
(int -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('a, 'b) Safe.t ->
'c ->
('b, 'd) t ->
('b, 'd) resval put_byte :
ctor:
(('a -> ([< `Rd | `Wr Wr ] as 'b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res) ->
('d, 'c) state) ->
int ->
('a -> ('b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res) ->
'a ->
('b, 'c) Safe.t ->
('d, 'c) t ->
('d, 'c) resval fill_byte :
ctor:
(('a -> ([< `Rd | `Wr Wr ] as 'b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res) ->
('d, 'c) state) ->
int ->
int ->
('a -> ('b, 'c) Safe.t -> ('d, 'c) t -> ('d, 'c) res) ->
'a ->
('b, 'c) Safe.t ->
('d, 'c) t ->
('d, 'c) resval peek_bits :
ctor:
((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('b, 'd) state) ->
int ->
(('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('a, 'b) Safe.t ->
'c ->
('b, 'd) t ->
('b, 'd) resval drop_bits :
ctor:
((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('b, 'd) state) ->
int ->
(('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('a, 'b) Safe.t ->
'c ->
('b, 'd) t ->
('b, 'd) resval get_bits :
ctor:
((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('b, 'd) state) ->
int ->
(int -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('a, 'b) Safe.t ->
'c ->
('b, 'd) t ->
('b, 'd) resval get_with_holding :
ctor:
((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('b, 'd) state) ->
(int -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('a, 'b) Safe.t ->
'c ->
('b, 'd) t ->
('b, 'd) resval get_int16 :
ctor:
((([< `Rd | `Wr Rd ] as 'a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('b, 'd) state) ->
(int -> ('a, 'b) Safe.t -> 'c -> ('b, 'd) t -> ('b, 'd) res) ->
('a, 'b) Safe.t ->
'c ->
('b, 'd) t ->
('b, 'd) resmodule KLast : sig ... endmodule KFlat : sig ... endval fixed : 'a -> 'b -> ('c, 'd) t -> ('c, 'd) resval switch : 'a -> 'b -> ('c, 'd) t -> ('c, 'd) resexception Exn_invalid_distance of int * intval block : ([< `Rd | `Wr Rd ], 'a) Safe.t -> 'b -> ('a, 'a) t -> ('a, 'a) resval last : ([< `Rd | `Wr Rd ], 'a) Safe.t -> 'b -> ('a, 'c) t -> ('a, 'c) resval eval :
'a ->
'a ->
('a, 'a) t ->
[> `Await of ('a, 'a) t
| `End of ('a, 'a) t
| `Error of ('a, 'a) t * error
| `Flush of ('a, 'a) t ]val default : witness:'a B.t -> ?wbits:int -> 'a Window.t -> ('a, 'a) tval refill : int -> int -> ('a, 'b) t -> ('a, 'b) tval flush : int -> int -> ('a, 'b) t -> ('a, 'b) tval used_in : ('a, 'b) t -> intval used_out : ('a, 'b) t -> intval write : ('a, 'b) t -> intval bits_remaining : ('a, 'b) t -> intinclude sig ... end
val to_result :
'a ->
'a ->
('a -> int) ->
('a -> int -> int) ->
('a, 'a) t ->
(('a, 'a) t, error) resultval bytes :
'a ->
'a ->
('a -> int) ->
('a -> int -> int) ->
('a, 'a) t ->
(('a, 'a) t, error) resultval bigstring :
'a ->
'a ->
('a -> int) ->
('a -> int -> int) ->
('a, 'a) t ->
(('a, 'a) t, error) result