> Hello. Why do we have something like
>
>        vlong Boffset(Biobufhdr *r);
>
> instead of
>
>        vlong Boffset(Biobuf *r);

Because there is an anonymous Biobufhdr
in the Biobuf, so it doesn't matter.  At one point,
it was possible to declare your own buffered
i/o by just embedding a Biobufhdr and filling
it in correctly.

>        long Bgetrune(Biobuf *r);
>
> instead of
>
>        Rune Bgetrune(Biobuf *r);

Because Bgetrune needs to be able to return -1 on EOF.

Russ

Reply via email to