core-wg / yang-cbor

Internet-Draft for CBOR representation of YANG data
5 stars 10 forks source link

enumerating the branches of a union is poorly done #127

Closed mcr closed 2 years ago

mcr commented 2 years ago

Values of 'enumeration' types defined in a 'union' type MUST be encoded using a CBOR text string data item (major type 3) and MUST contain one of the names assigned by 'enum' statements in YANG. The encoding MUST be enclosed by the enumeration CBOR tag as specified in {{tag-registry}}.

the use of strings here is going to blow up the size of things, and a better encoding is sought.

mcr commented 2 years ago

RFC7950 "9.12.2" https://datatracker.ietf.org/doc/html/rfc7950#section-9.12