ubjson / universal-binary-json

Community workspace for the Universal Binary JSON Specification.
115 stars 12 forks source link

Specification should clarify order of type and count in optimized containers #40

Closed earlchew closed 10 years ago

earlchew commented 10 years ago

http://ubjson.org/type-reference/container-types/#optimized-format

The text does not specify the order of type and count options when both are present.

Does type precede count ? Does count precede type ? Or are both orders supported ?

ghost commented 10 years ago

Great catch, it absolutely should be concretely specified (it is sort of implied right now from the examples and optional qualifications).

To your specific questions:

  1. Yes, if it is provided (optional)
  2. No, if type is provided, count must always come after.
  3. No

FIXED