The extended list needs a separate parameter and make the `line_start` match the `newline_last` at the start of the function.
Record `newline_last` and `line_start` whenever possible once a new line is found.
Use the variable `comment_start` to make the purpose more clear.
The `closes` array should be initialized before calling `fl_fss_extended_list_content_read()`.
Make sure the `closes` array value is reset when the Content is not found.
Make sure the `closes` array used length is incremented.
The FSS Read functions now handle printing the close strings.
I am now considering adding an `open` variable.
Doing this would then merit moving most things into the `f_fss_item_t`.
Tweak some of the allocations in other FSS functions for allocations that need explicit sizes (`f_memory_array_increase_by()`).
// Objects cannot be empty, so write a quote empty string.
{
- const f_status_t status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ const f_status_t status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
destination->used = destination_used;
}
// Ensure that there is room for a slash delimit and possibly the end of content character.
- state->status = f_memory_array_increase_by(state->step_small + 3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) return;
const f_number_unsigned_t destination_used = destination->used;
if (content.string[range->start] == f_fss_eol_s.string[0] || range->start >= content.used || range->start > range->stop) {
// Increase by slash and basic list open and possible newline.
- state->status = f_memory_array_increase_by(state->step_small + 3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) break;
destination->string[destination->used++] = f_fss_slash_s.string[0];
if (state->status == F_okay_stop || state->status == F_okay_eos) {
if (complete == f_fss_complete_partial_e || complete == f_fss_complete_partial_trim_e || complete == f_fss_complete_full_e || complete == f_fss_complete_full_trim_e) {
{
- const f_status_t status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ const f_status_t status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
state->status = status;
if (range->start > range->stop || range->start >= content.used) {
if (complete == f_fss_complete_full_e || complete == f_fss_complete_full_trim_e || complete == f_fss_complete_end_e) {
- const f_status_t status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ const f_status_t status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
state->status = status;
}
// Increase by character at "start" and possible newline.
- state->status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) break;
destination->string[destination->used++] = content.string[start];
}
// Increase by slash and extended list open and possible newline.
- state->status = f_memory_array_increase_by(state->step_small + 3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) break;
destination->string[destination->used++] = f_fss_slash_s.string[0];
}
if (complete == f_fss_complete_full_e || complete == f_fss_complete_full_trim_e || complete == f_fss_complete_end_e) {
- state->status = f_memory_array_increase_by(state->step_small + 3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) return;
if (!ends_on_eol) {
if (state->status == F_data_not_stop || state->status == F_data_not_eos) {
if (complete == f_fss_complete_partial_e || complete == f_fss_complete_partial_trim_e || complete == f_fss_complete_full_e || complete == f_fss_complete_full_trim_e) {
{
- const f_status_t status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ const f_status_t status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
state->status = status;
}
// Ensure that there is room for a slash delimit, the object open character, and the end of line character.
- state->status = f_memory_array_increase_by(state->step_small + 4, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(4, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) return;
const f_number_unsigned_t destination_used = destination->used;
}
if (complete != f_fss_complete_trim_e) {
- state->status = f_memory_array_increase_by(state->step_small + 3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) {
destination->used = destination_used;
if (state->status == F_data_not_stop || state->status == F_data_not_eos) {
// Content that is empty must be represented by a quote empty string.
- status = f_memory_array_increase_by(state->step_small + 4, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ status = f_memory_array_increase_by(4, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
state->status = status;
}
// Ensure that there is room, including the slash delimit and possibly the end of content characters.
- status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
state->status = status;
if (state->status == F_data_not_stop || state->status == F_data_not_eos) {
// Objects cannot be empty, so write a quote empty string.
- status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
destination->used = destination_used;
found->array[found->used].start = range->start;
+ f_number_unsigned_t line_start = range->start;
f_number_unsigned_t newline_last = range->start;
f_number_unsigned_t slash_first = 0;
f_number_unsigned_t slash_count = 0;
- f_number_unsigned_t line_start = 0;
+ f_number_unsigned_t comment_start = 0;
// Identify where the content ends.
while (range->start <= range->stop && range->start < buffer.used) {
if (range->start > range->stop || range->start >= buffer.used) break;
if (buffer.string[range->start] == f_fss_eol_s.string[0]) {
+ newline_last = range->start;
+ line_start = range->start + 1;
+
state->status = f_memory_array_increase(state->step_small, sizeof(f_number_unsigned_t), (void **) &delimits->array, &delimits->used, &delimits->size);
if (F_status_is_error(state->status)) break;
} // while
if (F_status_is_error(state->status)) break;
-
if (range->start > range->stop || range->start >= buffer.used) break;
// Found a valid content close, set stop point to last newline.
if (buffer.string[range->start] == f_fss_comment_s.string[0]) {
// The newline_last is initialized to the range->start, which may not actually be a new line.
- line_start = (buffer.string[newline_last] == f_string_eol_s.string[0]) ? newline_last + 1 : newline_last;
+ comment_start = (buffer.string[newline_last] == f_string_eol_s.string[0]) ? newline_last + 1 : newline_last;
f_fss_seek_to_eol(buffer, range, state);
if (F_status_is_error(state->status)) break;
- state->status = f_memory_array_increase(state->step_small, sizeof(f_range_t), (void **) &comments->array, &comments->used, &comments->size);
- if (F_status_is_error(state->status)) break;
-
if (range->start > range->stop || range->start >= buffer.used) {
--range->start;
}
else {
newline_last = range->start;
+ line_start = newline_last + 1;
}
- comments->array[comments->used].start = line_start;
- comments->array[comments->used++].stop = range->start++;
+ state->status = f_memory_array_increase(state->step_small, sizeof(f_range_t), (void **) &comments->array, &comments->used, &comments->size);
+ if (F_status_is_error(state->status)) break;
- // The newline_last is initialized to the range->start, which may not actually be a new line.
- line_start = (buffer.string[newline_last] == f_string_eol_s.string[0]) ? newline_last + 1 : newline_last;
+ comments->array[comments->used].start = comment_start;
+ comments->array[comments->used++].stop = range->start++;
continue;
}
if (range->start > range->stop || range->start >= content.used) {
if (complete == f_fss_complete_full_e || complete == f_fss_complete_full_trim_e || complete == f_fss_complete_end_e) {
{
- const f_status_t status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ const f_status_t status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
state->status = status;
}
// Ensure that there is room for a slash delimit and possibly the end of content characters.
- state->status = f_memory_array_increase_by(state->step_small + 4, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(4, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) return;
const f_number_unsigned_t destination_used = destination->used;
slash_count = 1;
if (do_prepend) {
- state->status = f_memory_array_increase_by(state->step_small + prepend->used, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(prepend->used, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) break;
state->status = f_string_dynamic_append(*prepend, destination);
// Do nothing.
}
else if (content.string[range->start] == f_fss_eol_s.string[0] || range->start >= content.used || range->start > range->stop) {
- state->status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) break;
destination->string[destination->used++] = f_fss_slash_s.string[0];
}
// Increase by character at "start" and possible newline.
- state->status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) break;
destination->string[destination->used++] = content.string[start];
}
// Increase by slash and extended list close.
- state->status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) break;
destination->string[destination->used++] = f_fss_slash_s.string[0];
}
if (complete == f_fss_complete_full_e || complete == f_fss_complete_full_trim_e || complete == f_fss_complete_end_e) {
- state->status = f_memory_array_increase_by(state->step_small + 3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) {
destination->used = destination_used;
f_number_unsigned_t slash_first = 0;
f_number_unsigned_t slash_count = 0;
- bool graph_first = F_true;
+ uint8_t graph_first = F_true;
// Identify where the object ends.
while (range->start <= range->stop && range->start < buffer.used && buffer.string[range->start] != f_fss_eol_s.string[0]) {
if (state->status == F_data_not_stop || state->status == F_data_not_eos) {
if (complete == f_fss_complete_partial_e || complete == f_fss_complete_partial_trim_e || complete == f_fss_complete_full_e || complete == f_fss_complete_full_trim_e) {
{
- const f_status_t status = f_memory_array_increase_by(state->step_small + 2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ const f_status_t status = f_memory_array_increase_by(2, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(status)) {
state->status = status;
}
// Ensure that there is room for a slash delimit, the object open character, and the end of line character.
- state->status = f_memory_array_increase_by(state->step_small + 4, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(4, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) return;
const f_number_unsigned_t destination_used = destination->used;
}
if (complete != f_fss_complete_trim_e) {
- state->status = f_memory_array_increase_by(state->step_small + 3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
+ state->status = f_memory_array_increase_by(3, sizeof(f_char_t), (void **) &destination->string, &destination->used, &destination->size);
if (F_status_is_error(state->status)) {
destination->used = destination_used;
f_number_unsigned_t initial_used = 0;
- bool found_data = F_false;
+ uint8_t found_data = F_false;
if (!nest->used) {
state->status = f_memory_array_increase(state->step_small, sizeof(f_fss_nest_t), (void **) &nest->depth, &nest->used, &nest->size);
f_status_t status = F_okay;
f_number_unsigned_t initial_used = objects->used;
- bool found_data = F_false;
+ uint8_t found_data = F_false;
do {
state->status = f_memory_array_increase(state->step_small, sizeof(f_range_t), (void **) &objects->array, &objects->used, &objects->size);
if (state->status == F_fss_found_object) {
found_data = F_true;
contents->array[contents->used].used = 0;
+ closes->array[closes->used].start = 1;
+ closes->array[closes->used].stop = 0;
fl_fss_extended_list_content_read(buffer, range, &contents->array[contents->used], &closes->array[closes->used], contents_delimits ? contents_delimits : objects_delimits, comments, state);
if (F_status_is_error(state->status)) return;
++contents->array[contents->used++].used;
++objects->used;
+ // The Content end is not found so make sure the closes designates that the close is not found.
+ closes->array[closes->used].start = 1;
+ closes->array[closes->used++].stop = 0;
+
return;
}
}
contents->array[contents->used].used = 0;
+ closes->array[closes->used].start = 1;
+ closes->array[closes->used].stop = 0;
}
if (range->start >= range->stop || range->start >= buffer.used) {
if (state->status == F_fss_found_object || state->status == F_fss_found_content || state->status == F_fss_found_content_not || state->status == F_fss_found_object_content_not) {
++objects->used;
++contents->used;
+ ++closes->used;
}
state->status = (range->start >= buffer.used) ? F_okay_eos : F_okay_stop;
++objects->used;
++contents->used;
+ ++closes->used;
} while (range->start < F_string_t_size_d);
#endif // _di_fss_read_embedded_list_print_object_end_empty_
#ifndef _di_fss_read_embedded_list_print_set_end_
- f_status_t fss_read_embedded_list_print_set_end(fl_print_t * const print) {
+ f_status_t fss_read_embedded_list_print_set_end(fl_print_t * const print, const f_number_unsigned_t close) {
if (!print || !print->custom) return F_status_set_error(F_output_not);
if ((main->setting.flag & fss_read_main_flag_object_d) && (main->setting.flag & fss_read_main_flag_content_d)) {
f_file_stream_lock(print->to);
- f_print_dynamic_raw(f_fss_embedded_list_close_s, print->to);
+ if (close < main->setting.closes.used) {
+ f_print_dynamic_partial(main->setting.buffer, main->setting.closes.array[close], print->to);
+ }
+ else {
+ f_print_dynamic_raw(f_fss_embedded_list_close_s, print->to);
+ }
+
f_print_dynamic_raw(f_fss_embedded_list_close_end_s, print->to);
f_file_stream_unlock(print->to);
* The print.custom is expected to be of type fss_read_main_t.
*
* This does not alter print.custom.setting.state.status.
+ * @param close
+ * The position within the close array representing the range within the buffer for the close string.
*
* @return
* F_okay on success.
* F_output_not (with error bit) if a parameter is NULL.
*/
#ifndef _di_fss_read_embedded_list_print_set_end_
- extern f_status_t fss_read_embedded_list_print_set_end(fl_print_t * const print);
+ extern f_status_t fss_read_embedded_list_print_set_end(fl_print_t * const print, const f_number_unsigned_t close);
#endif // _di_fss_read_embedded_list_print_set_end_
/**
return;
}
- if ((main->setting.flag & fss_read_main_flag_depth_d) && main->setting.nest.used > 1) {
+ if ((main->setting.flag & fss_read_main_flag_depth_d) && depth && main->setting.nest.used > 1) {
f_number_unsigned_t i = 0;
// @todo make an array of depths based on size.
main->setting.state.status = f_memory_array_resize(main->setting.nest.depth[depth].used, sizeof(f_range_t), (void **) &main->setting.objects.array, &main->setting.objects.used, &main->setting.objects.size);
if (F_status_is_error(main->setting.state.status)) return;
+ main->setting.state.status = f_memory_array_resize(main->setting.nest.depth[depth].used, sizeof(f_range_t), (void **) &main->setting.closes.array, &main->setting.closes.used, &main->setting.closes.size);
+ if (F_status_is_error(main->setting.state.status)) return;
+
main->setting.state.status = f_memory_array_resize(main->setting.nest.depth[depth].used, sizeof(f_ranges_t), (void **) &main->setting.contents.array, &main->setting.contents.used, &main->setting.contents.size);
if (F_status_is_error(main->setting.state.status)) return;
for (; main->setting.objects.used < main->setting.nest.depth[depth].used; ++main->setting.objects.used) {
main->setting.objects.array[main->setting.objects.used] = main->setting.nest.depth[depth].array[main->setting.objects.used].object;
+ main->setting.closes.array[main->setting.objects.used] = main->setting.nest.depth[depth].array[main->setting.objects.used].close;
// Use a static array for the inner Content that points to the depth, and so ensure the size is 0 to designate this is not dynamically allocated here.
if (main->setting.nest.depth[depth].array[main->setting.objects.used].content.used) {
}
} // for
+ main->setting.closes.used = main->setting.objects.used;
main->setting.contents.used = main->setting.objects.used;
fss_read_ensure_quotes_length(main);
#endif // _di_fss_read_extended_list_print_object_end_content_
#ifndef _di_fss_read_extended_list_print_set_end_
- f_status_t fss_read_extended_list_print_set_end(fl_print_t * const print) {
+ f_status_t fss_read_extended_list_print_set_end(fl_print_t * const print, const f_number_unsigned_t close) {
if (!print || !print->custom) return F_status_set_error(F_output_not);
if ((main->setting.flag & fss_read_main_flag_object_d) && main->setting.flag & fss_read_main_flag_content_d) {
f_file_stream_lock(print->to);
- f_print_dynamic_raw(f_fss_extended_list_close_s, print->to);
+ if (close < main->setting.closes.used) {
+ f_print_dynamic_partial(main->setting.buffer, main->setting.closes.array[close], print->to);
+ }
+ else {
+ f_print_dynamic_raw(f_fss_extended_list_close_s, print->to);
+ }
+
f_print_dynamic_raw(f_fss_extended_list_close_end_s, print->to);
f_file_stream_unlock(print->to);
* The print.custom is expected to be of type fss_read_main_t.
*
* This does not alter print.custom.setting.state.status.
+ * @param close
+ * The position within the close array representing the range within the buffer for the close string.
*
* @return
* F_okay on success.
* F_output_not (with error bit) if a parameter is NULL.
*/
#ifndef _di_fss_read_extended_list_print_set_end_
- extern f_status_t fss_read_extended_list_print_set_end(fl_print_t * const print);
+ extern f_status_t fss_read_extended_list_print_set_end(fl_print_t * const print, const f_number_unsigned_t close);
#endif // _di_fss_read_extended_list_print_set_end_
/**
* The FSS Read cache.
*
* objects: An Objects array used by the fll_fss_embedded_list_read() function.
- * closes: An Object closes array used by the fll_fss_embedded_list_read() function.
* positions: A positions array used by the fll_fss_embedded_list_read() function.
* slashes: A slashes array used by the fll_fss_embedded_list_read() function.
*/
#ifndef _di_fss_read_cache_t_
typedef struct {
f_ranges_t objects;
- f_ranges_t closes;
f_number_unsigneds_t positions;
f_number_unsigneds_t slashes;
} fss_read_cache_t;
- #define fss_read_cache_t_initialize { f_ranges_t_initialize, f_ranges_t_initialize, f_number_unsigneds_t_initialize, f_number_unsigneds_t_initialize }
+ #define fss_read_cache_t_initialize { f_ranges_t_initialize, f_number_unsigneds_t_initialize, f_number_unsigneds_t_initialize }
#endif // _di_fss_read_cache_t_
/**
f_status_t (*print_content_next)(fl_print_t * const print);
f_status_t (*print_object_end)(fl_print_t * const print);
f_status_t (*print_object_end_empty)(fl_print_t * const print);
- f_status_t (*print_set_end)(fl_print_t * const print);
+ f_status_t (*print_set_end)(fl_print_t * const print, const f_number_unsigned_t close);
f_status_t (*print_set_end_empty)(fl_print_t * const print);
} fss_read_callback_t;
if ((print_state & 0x1) || !(print_state & 0x10)) {
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
}
}
}
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
}
}
}
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
}
#endif // _di_fss_read_print_quote_
#ifndef _di_fss_read_print_set_end_
- f_status_t fss_read_print_set_end(fl_print_t * const print) {
+ f_status_t fss_read_print_set_end(fl_print_t * const print, const f_number_unsigned_t close) {
if (!print || !print->custom) return F_status_set_error(F_output_not);
#endif // _di_fss_read_print_set_end_
#ifndef _di_fss_read_print_set_end_no_eol_
- f_status_t fss_read_print_set_end_no_eol(fl_print_t * const print) {
+ f_status_t fss_read_print_set_end_no_eol(fl_print_t * const print, const f_number_unsigned_t close) {
if (!print || !print->custom) return F_status_set_error(F_output_not);
* The print.custom is expected to be of type fss_read_main_t.
*
* This does not alter print.custom.setting.state.status.
+ * @param close
+ * The position within the close array representing the range within the buffer for the close string.
*
* @return
* F_okay on success.
* F_output_not (with error bit) if a parameter is NULL.
*/
#ifndef _di_fss_read_print_set_end_
- extern f_status_t fss_read_print_set_end(fl_print_t * const print);
+ extern f_status_t fss_read_print_set_end(fl_print_t * const print, const f_number_unsigned_t close);
#endif // _di_fss_read_print_set_end_
/**
* The print.custom is expected to be of type fss_read_main_t.
*
* This does not alter print.custom.setting.state.status.
+ * @param close
+ * The position within the close array representing the range within the buffer for the close string.
*
* @return
* F_okay on success.
* F_output_not (with error bit) if a parameter is NULL.
*/
#ifndef _di_fss_read_print_set_end_no_eol_
- extern f_status_t fss_read_print_set_end_no_eol(fl_print_t * const print);
+ extern f_status_t fss_read_print_set_end_no_eol(fl_print_t * const print, const f_number_unsigned_t close);
#endif // _di_fss_read_print_set_end_no_eol_
#ifdef __cplusplus
if (!(main->setting.flag & fss_read_main_flag_object_as_line_d)) {
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
}
if (!(main->setting.flag & fss_read_main_flag_object_as_line_d)) {
if (*line == main->setting.line) {
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
main->setting.state.status = F_success;
else if (main->setting.flag & fss_read_main_flag_empty_d) {
if (*line == main->setting.line) {
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
main->setting.state.status = F_success;
if (main->setting.flag & fss_read_main_flag_empty_d) {
if (*line == main->setting.line) {
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
main->setting.state.status = F_success;
}
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
main->setting.state.status = F_success;
if ((main->setting.flag & fss_read_main_flag_object_d) && (main->setting.flag & fss_read_main_flag_content_has_close_d)) {
if (*line == main->setting.line) {
if (main->callback.print_set_end) {
- main->callback.print_set_end(&main->program.output);
+ main->callback.print_set_end(&main->program.output, at);
}
main->setting.state.status = F_success;