-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: exploring CBOR, protobuf #51
base: main
Are you sure you want to change the base?
Conversation
@dckc ya rang? taking a look. |
cc @gibson042 for CBOR experience. |
encoder.pushAny("S"); | ||
encoder.pushAny(value.toString()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oops... this should be 1 array of 2 items: the "S" tag and the string
} else if (value instanceof Error) { | ||
encoder._pushTag(SELF_DESCRIBED); | ||
encoder.pushAny("E"); | ||
encoder._pushInt(2, MT.ARRAY); | ||
encoder.pushAny(value.name); | ||
encoder.pushAny(value.message); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
likewise, this SELF_DESCRIBED should be followed by 1 array of 3 items: "E" tag, name, message.
I’ve got no CBOR experience, but I’m glad we’ve got evidence that CBOR can house O’Cap’n’s data model. I see possible directions going forward:
|
I believe so, because CBOR is strictly more general than JSON. It supports |
refs: #3
This includes CBOR work noted earlier plus some playing around with protobuf and passables.
I don't know whether it should ever get merged.
cc @zarutian (I can't seem to request review from you).