-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feature(parser): custom subs on paragraphs #726
feature(parser): custom subs on paragraphs #726
Conversation
Codecov Report
@@ Coverage Diff @@
## master #726 +/- ##
==========================================
- Coverage 84.93% 84.91% -0.02%
==========================================
Files 76 76
Lines 5224 5311 +87
==========================================
+ Hits 4437 4510 +73
- Misses 496 505 +9
- Partials 291 296 +5 |
marking this PR as "draft" since there are still some substitutions to implements and tests to add in the |
dd5d31b
to
884c13a
Compare
make/go.mk
Outdated
@@ -42,12 +42,12 @@ generate: install-pigeon | |||
generate-optimized: install-pigeon | |||
@echo "generating the parser (optimized)..." | |||
@pigeon -optimize-parser \ | |||
-alternate-entrypoints AsciidocRawDocument,RawFile,TextDocument,DocumentRawBlock,FileLocation,IncludedFileLine,InlineLinks,LabeledListItemTerm,NormalBlockContent,NormalParagraphContent,VerseBlockContent,MarkdownQuoteBlockAttribution,InlineElements \ | |||
-alternate-entrypoints AsciidocRawDocument,RawFile,TextDocument,DocumentRawBlock,FileLocation,IncludedFileLine,InlineLinks,LabeledListItemTerm,NormalParagraphContentSubstitution,NormalBlockContentSubstitution,VerseBlockContentSubstitution,MarkdownQuoteBlockAttribution,InlineElements,QuotedTextSubstitution,NoneSubstitution,AttributesSubstitution,ReplacementsSubstitution \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My PR that moves this to go generate will need to be updated if this merges first. Or vice versa.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, I've taken this change into account in my latest commit (I pushed with --force
)
884c13a
to
fd51649
Compare
Support for one or more custom substitutions Starting with Rawline elements which are parsed and result in other elements. Subsequent substitutions only apply on the StringElements. At the end of the substitutions, the lines are preserved Also, fix issues with single line comments which should not start with spaces before the `//` marker Fixes bytesparadise#597 Signed-off-by: Xavier Coulon <[email protected]>
fd51649
to
9c77a19
Compare
Support for one or more custom substitutions
Starting with Rawline elements which are parsed
and result in other elements. Subsequent substitutions
only apply on the StringElements.
At the end of the substitutions, the lines are preserved
Also, fix issues with single line comments which should not
start with spaces before the
//
markerFixes #597
Signed-off-by: Xavier Coulon [email protected]