module Async : ASYNC
module Reader : READER with type 'a t = 'a Async.t


val read : ?level:Header.compatibility -> Reader.in_channel -> (Header.t, [ `Eof ]) result Async.t

Returns the next header block or throws End_of_stream if two consecutive zero-filled blocks are discovered. Assumes stream is positioned at the possible start of a header block. End_of_file is thrown if the stream unexpectedly fails