respec icon indicating copy to clipboard operation
respec copied to clipboard

Add EBNF highlighting

Open marcoscaceres opened this issue 4 years ago • 1 comments

Is your feature request related to a problem? Please describe.

ABNF is great, but EBNF is better :)

Describe the solution you'd like To support syntax highlighting of EBNF.

cc @gkellogg

marcoscaceres avatar May 11 '21 03:05 marcoscaceres

Note that the "official" definition of EBNF from XML does not use rule labels (e.g., [1]), which is common use in many recommendations. Adding it to the EBNF grammar actually creates a conflict, as it can be mistaken for a character range (e.g., [abc123]). The grammar I created adds it as part of the LHS rule.

Also common is to use more general regular expression character ranges (e.g., [a-zA-Z0-9]) rather than separate ranges and enums (see for example, Turtle IRIREF).

EBNF deserves its own specification.

gkellogg avatar May 11 '21 16:05 gkellogg