instaparse

2023-05-27T17:26:19.262879Z

I am trying to port a grammar from pegjs and it says it is an abnf grammar. I does not work the grammar starts like this: /* ----- A.1 Lexical Grammar ----- */ SourceCharacter = . WhiteSpace “whitespace” = “\t” / “\v” / “\f” / ” ” / “\u00A0” / “\uFEFF” / Zs LineTerminator = [\n\r\u2028\u2029] What is this and can I translate it to something Instaparse understands?

2023-05-27T22:47:57.777079Z

Looks nothing like the example abnf here https://en.m.wikipedia.org/wiki/Augmented_Backus%E2%80%93Naur_form

2023-05-27T22:49:16.584669Z

The "whitespace" (quoted like a terminal?) on the left of the = is like no grammar I've seen before

2023-05-27T22:56:25.174149Z

Ah, pegjs has its own grammar syntax, what you are likely looking at is the grammar for abnf grammars, written in the pegjs grammar syntax

2023-05-27T23:28:39.222989Z

Thank You - So it looks like I need to figure out pegjs grammar and manually translate to abnf