From 660990612f513c3c3be104c7f20de7e81ba41aee Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Sat, 23 Mar 2019 09:21:12 -0700 Subject: Update spec; allow internal delimiter runs to match if... both have lengths that are multiples of 3. See commonmark/commonmark#528. --- src/inlines.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/inlines.c b/src/inlines.c index bab607a..6e92aff 100644 --- a/src/inlines.c +++ b/src/inlines.c @@ -642,7 +642,8 @@ static void process_emphasis(subject *subj, delimiter *stack_bottom) { // interior closer of size 2 can't match opener of size 1 // or of size 1 can't match 2 if (!(closer->can_open || opener->can_close) || - ((opener->length + closer->length) % 3) != 0) { + closer->length % 3 == 0 || + (opener->length + closer->length) % 3 != 0) { opener_found = true; break; } -- cgit v1.2.3