Subject: [Cbor] Barry Leiba's Yes on draft-ietf-cbor-sequence-01: (with COMMENT)

From: Barry Leiba via Datatracker <[email-masked]>
Date: Wed, 11 Sep 2019 13:37:06 -0700

Barry Leiba has entered the following ballot position for
draft-ietf-cbor-sequence-01: Yes

When responding, please keep the subject line intact and reply to all
email addresses included in the To and CC lines. (Feel free to cut this
introductory paragraph, however.)

Please refer to https://www.ietf.org/iesg/statement/discuss-criteria.html
for more information about IESG DISCUSS and COMMENT positions.

The document, along with other ballot positions, can be found here:
https://datatracker.ietf.org/doc/draft-ietf-cbor-sequence/

----------------------------------------------------------------------
COMMENT:
----------------------------------------------------------------------

Thanks for a fine and mostly easy-to-read document.  There’s just one bit that
I find hard to read:

— Section 2 —

   Decoding a CBOR Sequence works as follows:

   o  If the CBOR Sequence is an empty sequence of bytes, the result is
      an empty sequence of CBOR data model values.

   o  Otherwise, decode a single CBOR data item from the bytes of the
      CBOR sequence, and insert the resulting CBOR data model value at
      the start of the result of decoding the rest of the bytes as a
      CBOR sequence.  (A streaming decoder would therefore simply
      deliver zero or more CBOR data model values, each of which as soon
      as the bytes making it up are available.)

I find the phrasing of the second bullet (the part “at the start of the result
of decoding the rest of the bytes as a CBOR sequence.”) really hard to parse. 
After a brief email exchange between Carsten and me before he zipped off on
holidays, I propose this minor re-wording:

NEW
   o  Otherwise, decode a single CBOR data item from the bytes of the
      CBOR sequence, and insert the resulting CBOR data model value at
      the start of the result of repeating this decoding process
      recursively.  (A streaming decoder would therefore simply
      deliver zero or more CBOR data model values, each as soon
      as the bytes making it up are available.)
END

Does that work for you, Carsten?

---

From: Carsten Bormann <[email-masked]>
Date: Wed, 25 Sep 2019 14:40:39 +0200

Hi Barry,

> https://datatracker.ietf.org/doc/draft-ietf-cbor-sequence/

Almost.  
This doesn’t say what the decoding process is applied to, so I added “with the remaining bytes”:

* Otherwise, decode a single CBOR data item from the bytes of the CBOR
  sequence, and insert the resulting CBOR data model value at the
  start of the result of repeating this decoding process recursively
  with the remaining bytes.  (A streaming decoder would therefore
  simply deliver zero or more CBOR data model values, each as soon as
  the bytes making it up are available.)

Now in https://github.com/cbor-wg/seq/commit/ffa99b279f6ba91176b1af418388873f57390585

Grüße, Carsten

---

From: Barry Leiba <[email-masked]>
Date: Wed, 25 Sep 2019 16:19:59 -0400

Thanks!

b