Skip to content
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

Use "preferred serialization" consistently. #9

Merged
merged 3 commits into from
Mar 3, 2024
Merged

Conversation

cabo
Copy link
Collaborator

@cabo cabo commented Mar 3, 2024

Close #8

@cabo cabo requested a review from laurencelundblade March 3, 2024 19:49
@@ -121,7 +121,7 @@ types 0/1 in a seamless way.
{{Section 4.2.2 of RFC8949@-cbor}} recommends handling this transition the same
way as with the transition between different integer representation
lengths in the basic generic data model, i.e., by mandating the
Preferred Encoding ({{Section 3.4.3 of RFC8949@-cbor}}).
Preferred Serialization ({{Section 3.4.3 of RFC8949@-cbor}}).

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this section 4.1 of 8949? I assumed preferred serialization is capitalized here because it is the title of the section.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was specifically about encoding of integers, 3.4.3:

The preferred serialization of an integer that can
   be represented using major type 0 or 1 is to encode it this way
   instead of as a bignum (which means that the empty string never
   occurs in a bignum when using preferred serialization)

Fixed the case, added "for all integers".

@@ -93,9 +93,9 @@ Requirements_ defined for CBOR in
{{Section 4.2.1 of RFC8949@-cbor}}.

In many cases, CBOR provides more than one way to encode a data item,
but also provides a recommendation for a *Preferred Encoding*.
but also provides a recommendation for a *Preferred Serialization*.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I'd make this not capitalized.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, emacs global substitute keeps the case; fixed this below.
Now mostly downcased.

@cabo cabo requested a review from laurencelundblade March 3, 2024 20:14
@cabo cabo merged commit ac3c2e7 into main Mar 3, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Terminology: preferred serialization or preferred encoding
2 participants