Skip to content

Use ABNF in spec #22

Open
Open
@finnp

Description

I noticed that it might be easier to understand and quicker to grasp to use BNF in the spec.

ndjson = *(JSON-line newline)
newline = %x0A                ; Line feed or Newline
JSON-line = JSON-Text \ %x0A ; JSON-Text without Newline character

JSON-line is the JSON-Text from the RFC7159 JSON spec without the usage of a the newline (\n) character.

This also makes clear that empty lines aren't actually allowed in the spec and that we merely recommend parsers to allow this as an option.

Also it easily shows that the last line should be a newline.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions