This looks very cool. Based on the examples, you might like XDR.

It’s far better than the other binary serialization protocols I’ve looked at / implemented. NFSv3 uses it, and it is compatible with a lot of the tricks you play, like in-place endian translation, branch avoidance, zero allocation use cases, etc:

https://www.rfc-editor.org/rfc/rfc1014

Thanks for the interesting link. :)