Closed 3Rafal closed 11 months ago
As seen in example below, 1. is rendered to 1\\..
1.
1\\.
utop # let inline = Inline.Text ("1.", Cmarkit.Meta.none);; val inline : Cmarkit.Inline.t = Cmarkit.Inline.Text ("1.", <abstr>) utop # let paragraph = Block.Paragraph.make inline;; val paragraph : Block.Paragraph.t = <abstr> utop # let bp = Block.Paragraph (paragraph, Meta.none);; val bp : Block.t = Cmarkit.Block.Paragraph (<abstr>, <abstr>) utop # let doc = Doc.make bp;; val doc : Doc.t = <abstr> utop # Cmarkit_commonmark.of_doc doc;; - : string = "1\\."
However, the same procedure for 2. will render just 2.. As I understand it, the code for this behavior is: https://github.com/dbuenzli/cmarkit/blob/f37c8ea86fd0be8dba7a8babcee3682e0e047d91/src/cmarkit_commonmark.ml#L74-L75
2.
I would assume that this escaping should work for all number+dot combinations.
See en example of similar problem shown in a different commonmark implementation: https://github.com/thephpleague/commonmark/blob/795851fa43b6981f7e751ae714788078075b2bbb/tests/benchmark/sample.md?plain=1#L450
Not sure exactly what went into my head when I did that. It's even documented.
As seen in example below,
1.
is rendered to1\\.
.However, the same procedure for
2.
will render just2.
. As I understand it, the code for this behavior is: https://github.com/dbuenzli/cmarkit/blob/f37c8ea86fd0be8dba7a8babcee3682e0e047d91/src/cmarkit_commonmark.ml#L74-L75I would assume that this escaping should work for all number+dot combinations.
See en example of similar problem shown in a different commonmark implementation: https://github.com/thephpleague/commonmark/blob/795851fa43b6981f7e751ae714788078075b2bbb/tests/benchmark/sample.md?plain=1#L450