To better support binary compatibility the parser implementations for markup formats (Markdown and reStructuredText) have been made private.
However, ideally there should be a convenient place for parser authors to at least make the top-level parsers available for other users in case they want to freely compose them for other purposes.
This is encouraged by changing MarkupFormat.spanParsers/blockParsers from a simple Seq to MarkupParsers[E].
The trait has only one abstract property (all: Seq[Block/SpanParserBuilder]), but can be used to add properties for individual parsers.
For example, the bullet list parser for Markdown can now be simply accessed via Markdown.blockParsers.bulletList. This convention is not possible when the property is a simple Seq.
To better support binary compatibility the parser implementations for markup formats (Markdown and reStructuredText) have been made private.
However, ideally there should be a convenient place for parser authors to at least make the top-level parsers available for other users in case they want to freely compose them for other purposes.
This is encouraged by changing
MarkupFormat.spanParsers/blockParsers
from a simpleSeq
toMarkupParsers[E]
. The trait has only one abstract property (all: Seq[Block/SpanParserBuilder]
), but can be used to add properties for individual parsers.For example, the bullet list parser for Markdown can now be simply accessed via
Markdown.blockParsers.bulletList
. This convention is not possible when the property is a simpleSeq
.