We have some duplication in the binary reader/writer code around things like type constants, we should consolidate hem.