Posted by mojavelinux on Mar 30, 2015; 12:28pm URL: https://discuss.asciidoctor.org/Asciidoc-syntax-definition-tp1920p2866.html
Several people have approached me recently about working on a formal / standard grammar and parser for AsciiDoc. I'm very glad to discover there's so much interest! I think the time is right to kick off the effort.
Initially, the work will be exploratory. I think we should start by focusing on the inline syntax (bold, italic, monospace, etc). I hope we can identify which parts of the syntax already work well in a formal grammar and which parts present problems (perhaps because they are too context sensitive). We'll also want to cleanup the terminology and iron out places where it's a bit quirky (for instance, "formatted text" instead of "quoted text").
I see two key goals for this effort:
* to enable multiple implementations of the parser (perhaps even a reference implementation in Java)
* make the syntax more consistent and predictable
I've been using the following wiki page to capture some information related to the effort:
Here's a list of people who have expressed interest in contributing:
* Martin van Rappard * Sebastian Daschner * Erik Pragt * Jakub Jirutka
* Vincent Massol
Feel free to add your name to this list (ideally on the wiki page).
I'd be interested in connecting with compiler groups at universities to see if any research projects can be formed around this effort. There are a lot of problems to explore with parsing lightweight markup languages (perhaps also aspects of natural language processing) that could make for interesting research and also help move AsciiDoc forward and evolve. If you know of anyone interested, please have them reach out (ideally through this list).
Here are the action items to get started:
Step 1. Choose a name for the GitHub repository name
Here are two possible names for the repo.
* asciidoc-grammar
* asciidoc-syntax
Should we use one of these or something else?
Step 2. Create an initial project structure.
Are we going to do it based on ANTLR 4 or some other parser? We'll need to decide that in order to create the initial project.
Who would like to do step 2?
Step 3. Hack!
I'm really excited about this initiative! Let's make it happen.