forked from bytesparadise/libasciidoc
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(parser): simplify grammar (bytesparadise#560)
Refactor multiple rules to simplify the grammar and make the parser more efficient: - use character groups instead of choices whenever applicable - refactor `ContinuedListItemElement` rule: ignore BlankLine, but take into account during preprocessing (when building lists) - move `LabeledListItem` alone before `SimpleParagraph` to simplify the latter - remove multiple occurrences of `!EOL !LineBreak` and `!EOF !BlankLine rules - simplify single quote/double quote bokld/monospace/italic text rules - merge TextOnlyLinkAttributes and TextAndMoreLinkAttributes rules - simplify FoonoteContent rule - simplify InlineElement rule - remove Anychars and Parenthesis rules, simplify AnyChar also: - define a makefile goal for the bench, using a separate .go file with a custom build tag so we can have the parse options. Fixes bytesparadise#557 Signed-off-by: Xavier Coulon <[email protected]>
- Loading branch information
Showing
39 changed files
with
9,581 additions
and
9,720 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.