possible bugfix for eating up newlines too ambitiously when ending unscoped sets

This commit is contained in:
Ryan Fleury
2021-12-29 09:21:39 -07:00
parent 7f12b05741
commit 2ceb1a1d7a
+8 -2
View File
@@ -2440,12 +2440,18 @@ MD_ParseNodeSet(MD_Arena *arena, MD_String8 string, MD_u64 offset, MD_Node *pare
if(potential_closer.kind == MD_TokenKind_Newline)
{
closer_check_off += potential_closer.raw_string.size;
off = closer_check_off;
// TODO(rjf): As far as I can tell, we can't actually do this,
// because higher-level unscoped sets may depend on this newline
// so they can be terminated.
// off = closer_check_off;
// NOTE(rjf): always terminate with a newline if we have >0 children
if(parsed_child_count > 0)
{
off = closer_check_off;
// TODO(rjf): As far as I can tell, we can't actually do this,
// because higher-level unscoped sets may depend on this newline
// so they can be terminated.
// off = closer_check_off;
got_closer = 1;
break;
}