The *Mem variants cannot return EndOfStream and are generally unsafe to use. Proper order of checks, try both the variants and make sure they return the same error/result. Run the leb128.zig tests.