From: Kevin Day Date: Sat, 2 Nov 2019 20:54:42 +0000 (-0500) Subject: Progress: do not include closing brace when determining stop point in extended list X-Git-Tag: 0.5.0~402 X-Git-Url: https://git.kevux.org/?a=commitdiff_plain;h=920da6b5bf0311a64ae588c444b2229b73544036;p=fll Progress: do not include closing brace when determining stop point in extended list --- diff --git a/level_1/fl_fss/c/fss_extended_list.c b/level_1/fl_fss/c/fss_extended_list.c index adeb5d8..c6db293 100644 --- a/level_1/fl_fss/c/fss_extended_list.c +++ b/level_1/fl_fss/c/fss_extended_list.c @@ -347,10 +347,10 @@ extern "C" { // this is a valid object open/close that has been delimited, save the slash delimit positions. if (buffer->string[location->start] == f_string_eol) { + f_string_length location_newline = location->start; if (is_open) { f_bool is_object = f_false; - f_string_length location_newline = location->start; if (slash_count % 2 == 0) { is_object = f_true; @@ -416,7 +416,6 @@ extern "C" { last_newline = location_newline; } else { - last_newline = location->start; location->start = slash_last; if (delimits.used + 1 >= delimits.size) { @@ -436,7 +435,7 @@ extern "C" { delimits.used++; } - location->start = last_newline; + location->start = location_newline; } } } @@ -645,11 +644,9 @@ extern "C" { found->array[depth].used++; found->used = positions_start.used; - if (depth == 0) { - last_newline = location->start; - break; - } + if (depth == 0) break; + last_newline = location->start; depth--; } // No valid object close found, seek until EOL. @@ -679,7 +676,9 @@ extern "C" { } } - last_newline = location->start; + if (depth > 0) { + last_newline = location->start; + } } position_previous = location->start;