pub fn until_exclusive<Reader, T, CondFn, Arg, Ret>(
cond: CondFn,
) -> impl Fn(&mut Reader, &ReadOptions, Arg) -> BinResult<Ret>
Expand description
Read items until a condition is met. The last item will not be named.
ยงExamples
#[derive(BinRead)]
struct NullTerminated {
#[br(parse_with = until_exclusive(|&byte| byte == 0))]
data: Vec<u8>,
}