cbor-wg / edn-literal

Application-oriented literals for CBOR extended diagnostic notation
Other
0 stars 7 forks source link

Superfluous `S` in ABNF #37

Closed chrysn closed 2 months ago

chrysn commented 3 months ago

There is a trailing S in the seq ABNF:

seq             = S [item S *("," S item S) OC] S

As far as I understand, if the [] is absent, any data that might go into the trailing S would go into the leading S. If it is present and OC contains a comma, then any data that might go into the trailing S would go into the OC. Otherwise, it would go into the last S of the repeat expression or into the S after the first item -- at any rate, no data can wind up in that position.

It does no harm, and it might be too late to change the ABNF -- but it should be documented somewhere, and this issue is as good as any place for it. Feel free to just close it if it's not going to be changed.