With MD_FLAG_STRIKETHROUGH, we are too benevolent and we can see any sequence of tildes as a strike-trough mark (except when in a code span or something like that).
Only marks of length 1 or 2 are accepted ~foo~ or ~~bar~~.
The length of opener and closer mark must match (~foo~~ won't be strike-through).
It now checks similarly as other emphasis marks whether it is followed/preceded with a white-space (e.g. in ~foo ~ the latter ~ is not recognized as a closer).
As all those changes seems very reasonable, we shall follow it.
With
MD_FLAG_STRIKETHROUGH
, we are too benevolent and we can see any sequence of tildes as a strike-trough mark (except when in a code span or something like that).This followed some original behavior of cmark-gfm but it seems that cmark-gfm later became much stricter.
From my testing it seems that:
~foo~ or ~~bar~~
.~foo~~
won't be strike-through).~foo ~
the latter~
is not recognized as a closer).As all those changes seems very reasonable, we shall follow it.