This collapses much of the code from fl_string into f_string.
I have originally wanted to keep f_string source file free to help reduce recursion but the design kept leading me to deciding to do this.
The final straw was the extern const strings.
This moves all of the string related functionality that does not strictly depend on f_utf into f_string.
I expect that the fl_utf and fl_string will be merged together into fl_string.
I also expect that following these changes and the related cleanups then I will be at a good point to update and get the UTF-8 processing code in sync with the current string processing code.
That is, the f_utf_string needs to work similar to f_string types as well as have the same functions.
This collapsing of the level 1 code into level 0 code will also require an update on all appropriate dependencies (header files being included, etc..).
I also strived for more completeness in this and added many missing functions and macros.
I did not get as far as I would like, resulting in this being a Progress commit instead of an Update commit.
build_libraries -lc -lcap
build_libraries-level
build_libraries-level_threadless
-build_sources_library account.c private-account.c capability.c color.c color-common.c console.c console-common.c control_group.c control_group-common.c conversion.c directory.c private-directory.c environment.c private-environment.c file.c file-common.c private-file.c fss.c iki.c iki-common.c private-iki.c limit.c memory.c memory_structure.c private-memory.c path.c path-common.c private-path.c pipe.c print.c private-print.c serialize.c serialize-common.c private-serialize.c signal.c socket.c string.c string-common.c utf.c private-utf.c
+build_sources_library account.c private-account.c capability.c color.c color-common.c console.c console-common.c control_group.c control_group-common.c conversion.c directory.c private-directory.c environment.c private-environment.c file.c file-common.c private-file.c fss.c iki.c iki-common.c private-iki.c limit.c memory.c memory_structure.c private-memory.c path.c path-common.c private-path.c pipe.c print.c private-print.c serialize.c serialize-common.c private-serialize.c signal.c socket.c string.c string-common.c private-string.c string_dynamic.c string_map.c string_quantity.c string_range.c string_triple.c utf.c private-utf.c
build_sources_library-level thread.c
build_sources_program
-build_sources_headers account.h account-common.h capability.h capability-common.h color.h color-common.h console.h console-common.h control_group.h control_group-common.h conversion.h conversion-common.h directory.h directory_type.h directory-common.h environment.h environment-common.h execute.h execute-common.h file.h file-common.h fss.h fss-common.h fss_comment.h fss_delimit.h fss_named.h fss_nest.h fss_quote.h fss_set.h iki.h iki-common.h limit.h limit-common.h memory.h memory_structure.h memory-common.h path.h path-common.h pipe.h print.h serialize.h serialize-common.h signal.h signal-common.h socket.h socket-common.h status.h status_array.h string.h string-common.h string_dynamic.h string_map.h string_quantity.h string_range.h string_triple.h type.h type_array.h utf.h utf-common.h
+build_sources_headers account.h account-common.h capability.h capability-common.h color.h color-common.h console.h console-common.h control_group.h control_group-common.h conversion.h conversion-common.h directory.h directory_type.h directory-common.h environment.h environment-common.h execute.h execute-common.h file.h file-common.h fss.h fss-common.h fss_comment.h fss_delimit.h fss_named.h fss_nest.h fss_quote.h fss_set.h iki.h iki-common.h limit.h limit-common.h memory.h memory_structure.h memory-common.h path.h path-common.h pipe.h print.h serialize.h serialize-common.h signal.h signal-common.h socket.h socket-common.h status.h status_array.h string.h string-common.h private-string.h string_dynamic.h string_map.h string_quantity.h string_range.h string_triple.h type.h type_array.h utf.h utf-common.h
build_sources_headers-level thread.h thread-common.h
build_sources_script
build_sources_setting
build_libraries -lc -lcap
build_libraries-monolithic
build_libraries-monolithic_threadless
-build_sources_library level_0/account.c level_0/private-account.c level_0/capability.c level_0/color.c level_0/color-common.c level_0/console.c level_0/console-common.c level_0/control_group.c level_0/control_group-common.c level_0/conversion.c level_0/directory.c level_0/private-directory.c level_0/environment.c level_0/private-environment.c level_0/file.c level_0/file-common.c level_0/private-file.c level_0/fss.c level_0/iki.c level_0/iki-common.c level_0/private-iki.c level_0/limit.c level_0/memory.c level_0/memory_structure.c level_0/private-memory.c level_0/path.c level_0/path-common.c level_0/private-path.c level_0/pipe.c level_0/print.c level_0/private-print.c level_0/serialize.c level_0/serialize-common.c level_0/private-serialize.c level_0/signal.c level_0/socket.c level_0/string.c level_0/string-common.c level_0/utf.c level_0/private-utf.c level_1/color.c level_1/console.c level_1/control_group.c level_1/conversion.c level_1/directory.c level_1/private-directory.c level_1/environment.c level_1/private-fss.c level_1/fss_basic.c level_1/fss_basic_list.c level_1/fss_embedded_list.c level_1/fss_extended.c level_1/fss_extended_list.c level_1/iki.c level_1/print.c level_1/private-print.c level_1/status.c level_1/string.c level_1/private-string.c level_1/type.c level_1/private-type.c level_1/utf.c level_1/private-utf.c level_1/utf_file.c level_1/private-utf_file.c level_2/control_group.c level_2/environment.c level_2/error.c level_2/error-common.c level_2/private-error.c level_2/execute.c level_2/private-execute.c level_2/file.c level_2/private-file.c level_2/fss.c level_2/private-fss.c level_2/fss_basic.c level_2/fss_basic_list.c level_2/fss_embedded_list.c level_2/fss_extended.c level_2/fss_extended_list.c level_2/fss_status.c level_2/iki.c level_2/private-iki.c level_2/path.c level_2/program.c level_2/status.c
+build_sources_library level_0/account.c level_0/private-account.c level_0/capability.c level_0/color.c level_0/color-common.c level_0/console.c level_0/console-common.c level_0/control_group.c level_0/control_group-common.c level_0/conversion.c level_0/directory.c level_0/private-directory.c level_0/environment.c level_0/private-environment.c level_0/file.c level_0/file-common.c level_0/private-file.c level_0/fss.c level_0/iki.c level_0/iki-common.c level_0/private-iki.c level_0/limit.c level_0/memory.c level_0/memory_structure.c level_0/private-memory.c level_0/path.c level_0/path-common.c level_0/private-path.c level_0/pipe.c level_0/print.c level_0/private-print.c level_0/serialize.c level_0/serialize-common.c level_0/private-serialize.c level_0/signal.c level_0/socket.c level_0/string.c level_0/string-common.c level_0/private-string.c level_0/string_dynamic.c level_0/string_map.c level_0/string_quantity.c level_0/string_range.c level_0/string_triple.c level_0/utf.c level_0/private-utf.c level_1/color.c level_1/console.c level_1/control_group.c level_1/conversion.c level_1/directory.c level_1/private-directory.c level_1/environment.c level_1/private-fss.c level_1/fss_basic.c level_1/fss_basic_list.c level_1/fss_embedded_list.c level_1/fss_extended.c level_1/fss_extended_list.c level_1/iki.c level_1/print.c level_1/private-print.c level_1/status.c level_1/string.c level_1/private-string.c level_1/type.c level_1/private-type.c level_1/utf.c level_1/private-utf.c level_1/utf_file.c level_1/private-utf_file.c level_2/control_group.c level_2/environment.c level_2/error.c level_2/error-common.c level_2/private-error.c level_2/execute.c level_2/private-execute.c level_2/file.c level_2/private-file.c level_2/fss.c level_2/private-fss.c level_2/fss_basic.c level_2/fss_basic_list.c level_2/fss_embedded_list.c level_2/fss_extended.c level_2/fss_extended_list.c level_2/fss_status.c level_2/iki.c level_2/private-iki.c level_2/path.c level_2/program.c level_2/status.c
build_sources_library-monolithic level_0/thread.c
build_sources_program
-build_sources_headers level_0/account.h level_0/account-common.h level_0/capability.h level_0/capability-common.h level_0/color.h level_0/color-common.h level_0/console.h level_0/console-common.h level_0/control_group.h level_0/control_group-common.h level_0/conversion.h level_0/conversion-common.h level_0/directory.h level_0/directory_type.h level_0/directory-common.h level_0/environment.h level_0/environment-common.h level_0/execute.h level_0/execute-common.h level_0/file.h level_0/file-common.h level_0/fss.h level_0/fss-common.h level_0/fss_comment.h level_0/fss_delimit.h level_0/fss_named.h level_0/fss_nest.h level_0/fss_quote.h level_0/fss_set.h level_0/iki.h level_0/iki-common.h level_0/limit.h level_0/limit-common.h level_0/memory.h level_0/memory_structure.h level_0/memory-common.h level_0/path.h level_0/path-common.h level_0/pipe.h level_0/print.h level_0/serialize.h level_0/serialize-common.h level_0/signal.h level_0/signal-common.h level_0/socket.h level_0/socket-common.h level_0/status.h level_0/status_array.h level_0/string.h level_0/string-common.h level_0/string_dynamic.h level_0/string_map.h level_0/string_quantity.h level_0/string_range.h level_0/string_triple.h level_0/type.h level_0/type_array.h level_0/utf.h level_0/utf-common.h level_1/color.h level_1/console.h level_1/control_group.h level_1/conversion.h level_1/directory.h level_1/environment.h level_1/execute.h level_1/execute-common.h level_1/fss.h level_1/fss_basic.h level_1/fss_basic_list.h level_1/fss_embedded_list.h level_1/fss_extended.h level_1/fss_extended_list.h level_1/fss_status.h level_1/iki.h level_1/print.h level_1/status.h level_1/string.h level_1/type.h level_1/utf.h level_1/utf_file.h level_2/control_group.h level_2/environment.h level_2/error.h level_2/error-common.h level_2/execute.h level_2/file.h level_2/fss.h level_2/fss_basic.h level_2/fss_basic_list.h level_2/fss_embedded_list.h level_2/fss_extended.h level_2/fss_extended_list.h level_2/fss_status.h level_2/iki.h level_2/path.h level_2/program.h level_2/status.h
+build_sources_headers level_0/account.h level_0/account-common.h level_0/capability.h level_0/capability-common.h level_0/color.h level_0/color-common.h level_0/console.h level_0/console-common.h level_0/control_group.h level_0/control_group-common.h level_0/conversion.h level_0/conversion-common.h level_0/directory.h level_0/directory_type.h level_0/directory-common.h level_0/environment.h level_0/environment-common.h level_0/execute.h level_0/execute-common.h level_0/file.h level_0/file-common.h level_0/fss.h level_0/fss-common.h level_0/fss_comment.h level_0/fss_delimit.h level_0/fss_named.h level_0/fss_nest.h level_0/fss_quote.h level_0/fss_set.h level_0/iki.h level_0/iki-common.h level_0/limit.h level_0/limit-common.h level_0/memory.h level_0/memory_structure.h level_0/memory-common.h level_0/path.h level_0/path-common.h level_0/pipe.h level_0/print.h level_0/serialize.h level_0/serialize-common.h level_0/signal.h level_0/signal-common.h level_0/socket.h level_0/socket-common.h level_0/status.h level_0/status_array.h level_0/string.h level_0/string-common.h level_0/private-string.h level_0/string_dynamic.h level_0/string_map.h level_0/string_quantity.h level_0/string_range.h level_0/string_triple.h level_0/type.h level_0/type_array.h level_0/utf.h level_0/utf-common.h level_1/color.h level_1/console.h level_1/control_group.h level_1/conversion.h level_1/directory.h level_1/environment.h level_1/execute.h level_1/execute-common.h level_1/fss.h level_1/fss_basic.h level_1/fss_basic_list.h level_1/fss_embedded_list.h level_1/fss_extended.h level_1/fss_extended_list.h level_1/fss_status.h level_1/iki.h level_1/print.h level_1/status.h level_1/string.h level_1/type.h level_1/utf.h level_1/utf_file.h level_2/control_group.h level_2/environment.h level_2/error.h level_2/error-common.h level_2/execute.h level_2/file.h level_2/fss.h level_2/fss_basic.h level_2/fss_basic_list.h level_2/fss_embedded_list.h level_2/fss_extended.h level_2/fss_extended_list.h level_2/fss_status.h level_2/iki.h level_2/path.h level_2/program.h level_2/status.h
build_sources_headers-monolithic level_0/thread.h level_0/thread-common.h
build_sources_script
build_sources_setting
/**
* Resize a generic memory structures.
*
- * status: the status to return.
- * structures: the structures to operate on.
- * type_stucture: the structure type.
- * type_stuctures: the structures type.
- * length: the new size of the array.
- * length_variable: the data type of the length variable.
+ * status: the status to return.
+ * structures: the structures to operate on.
+ * type_stucture: the structure type.
+ * type_stuctures: the structures type.
+ * length: the new size of the array.
+ * type_length: the data type of the length variable type.
*/
#ifndef _di_f_macro_memory_structures_resize_
- #define f_macro_memory_structures_resize(status, structures, type_structure, type_structures, length, length_variable) \
+ #define f_macro_memory_structures_resize(status, structures, type_structure, type_structures, length, type_length) \
status = F_none; \
if (length < structures.size) { \
- for (length_variable _macro__i = structures.size - length; _macro__i < structures.size; ++_macro__i) { \
+ for (type_length _macro__i = structures.size - length; _macro__i < structures.size; ++_macro__i) { \
f_macro_memory_structure_delete(status, structures.array[_macro__i], type_structure); \
if (status != F_none) break; \
} \
/**
* Adjust a generic memory structures.
*
- * status: the status to return.
- * structures: the structures to operate on.
- * type_stucture: the structure type.
- * type_stuctures: the structures type.
- * length: the new size of the array.
- * length_variable: the data type of the length variable.
+ * status: the status to return.
+ * structures: the structures to operate on.
+ * type_stucture: the structure type.
+ * type_stuctures: the structures type.
+ * length: the new size of the array.
+ * type_length: the data type of the length variable type.
*/
#ifndef _di_f_macro_memory_structures_adjust_
- #define f_macro_memory_structures_adjust(status, structures, type_structure, type_structures, length, length_variable) \
+ #define f_macro_memory_structures_adjust(status, structures, type_structure, type_structures, length, type_length) \
status = F_none; \
if (length < structures.size) { \
- for (length_variable _macro__i = structures.size - length; _macro__i < structures.size; ++_macro__i) { \
+ for (type_length _macro__i = structures.size - length; _macro__i < structures.size; ++_macro__i) { \
f_macro_memory_structure_destroy(status, structures.array[_macro__i], type_structure); \
if (status != F_none) break; \
} \
#endif // _di_f_macro_memory_structures_destroy_simple_
/**
+ * Increase a generic memory structures by 1.
+ *
+ * This only increases if the structure.used + 1 is greater than structure.size.
+ *
+ * status: the status to return.
+ * structures: the structures to operate on.
+ * type_stuctures: the structures type.
+ * type_length: the data type of the length variable type.
+ */
+#ifndef _di_f_macro_memory_structures_increase_
+ #define f_macro_memory_structures_increase(status, structures, type_structures, type_length) \
+ status = F_none; \
+ if (structures.used + 1 > structures.size) { \
+ type_length _macro__length = structures.used + f_memory_default_allocation_step; \
+ if (_macro__length > f_array_length_t_size) { \
+ if (structures.used + 1 > f_array_length_t_size) { \
+ status = F_status_set_error(F_array_too_large); \
+ } \
+ else { \
+ _macro__length = f_array_length_t_size; \
+ } \
+ } \
+ if (status == F_none) status = f_memory_resize((void **) & structures.array, sizeof(type_structures), structures.size, _macro__length); \
+ if (status == F_none) { \
+ structures.size = _macro__length; \
+ } \
+ } \
+ else { \
+ status = F_data_not; \
+ }
+#endif // _di_f_macro_memory_structures_increase_
+
+/**
+ * Decrease a generic memory structures by 1.
+ *
+ * status: the status to return.
+ * structures: the structures to operate on.
+ * type_stucture: the structure type.
+ * type_stuctures: the structures type.
+ */
+#ifndef _di_f_macro_memory_structures_decrease_
+ #define f_macro_memory_structures_decrease(status, structures, type_structure, type_structures) \
+ status = F_none; \
+ if (structures.size) { \
+ f_macro_memory_structure_delete(status, structures.array[structures.size - 1], type_structure); \
+ if (status == F_none) status = f_memory_resize((void **) & structures.array, sizeof(type_structures), structures.size, structures.size - 1); \
+ if (status == F_none) { \
+ structures.size--; \
+ if (structures.used > structures.size) structures.used = structures.size; \
+ } \
+ } \
+ else { \
+ status = F_data_not; \
+ }
+#endif // _di_f_macro_memory_structures_decrease_
+
+/**
+ * Decimate a generic memory structures by 1.
+ *
+ * status: the status to return.
+ * structures: the structures to operate on.
+ * type_stucture: the structure type.
+ * type_stuctures: the structures type.
+ */
+#ifndef _di_f_macro_memory_structures_decimate_
+ #define f_macro_memory_structures_decimate(status, structures, type_structure, type_structures) \
+ status = F_none; \
+ if (structures.size) { \
+ f_macro_memory_structure_destroy(status, structures.array[structures.size - 1], type_structure); \
+ if (status == F_none) status = f_memory_adjust((void **) & structures.array, sizeof(type_structures), structures.size, structures.size - 1); \
+ if (status == F_none) { \
+ structures.size--; \
+ if (structures.used > structures.size) structures.used = structures.size; \
+ } \
+ } \
+ else { \
+ status = F_data_not; \
+ }
+#endif // _di_f_macro_memory_structures_decimate_
+
+/**
+ * Increase a generic memory structures by the given amount.
+ *
+ * This only increases if the structure.used + amount is greater than structure.size.
+ *
+ * status: the status to return.
+ * structures: the structures to operate on.
+ * type_stuctures: the structures type.
+ * type_length: the data type of the length variable type.
+ * amount: the amount to increase by.
+ */
+#ifndef _di_f_macro_memory_structures_increase_by_
+ #define f_macro_memory_structures_increase_by(status, structures, type_structures, type_length, amount) \
+ status = F_none; \
+ if (structures.used + amount > structures.size) { \
+ if (amount > f_array_length_t_size) { \
+ status = F_status_set_error(F_array_too_large); \
+ } \
+ if (status == F_none) status = f_memory_resize((void **) & structures.array, sizeof(type_structures), structures.size, amount); \
+ if (status == F_none) { \
+ structures.size = amount; \
+ } \
+ } \
+ else { \
+ status = F_data_not; \
+ }
+#endif // _di_f_macro_memory_structures_increase_by_
+
+/**
+ * Decrease a generic memory structures by the given amount.
+ *
+ * status: the status to return.
+ * structures: the structures to operate on.
+ * type_stucture: the structure type.
+ * type_stuctures: the structures type.
+ * amount: the amount to decrease by.
+ * type_length: the data type of the length variable type.
+ */
+#ifndef _di_f_macro_memory_structures_decrease_by_
+ #define f_macro_memory_structures_decrease_by(status, structures, type_structure, type_structures, amount, type_length) \
+ if (amount) { \
+ status = F_none; \
+ if (amount <= structures.size) { \
+ type_length _macro__length = structures.size - amount; \
+ f_macro_memory_structures_resize(status, structures, type_structure, type_structures, _macro__length, type_length); \
+ } \
+ else { \
+ f_macro_memory_structures_delete(status, structures, type_structure, type_structures); \
+ if (status == F_none) { \
+ structures.used = 0; \
+ structures.size = 0; \
+ } \
+ } \
+ } \
+ else { \
+ status = F_data_not; \
+ }
+#endif // _di_f_macro_memory_structures_decrease_by_
+
+/**
+ * Decimate a generic memory structures by the given amount.
+ *
+ * status: the status to return.
+ * structures: the structures to operate on.
+ * type_stucture: the structure type.
+ * type_stuctures: the structures type.
+ * amount: the amount to decimate by.
+ * type_length: the data type of the length variable type.
+ */
+#ifndef _di_f_macro_memory_structures_decimate_by_
+ #define f_macro_memory_structures_decimate_by(status, structures, type_structure, type_structures, amount, type_length) \
+ if (amount) { \
+ status = F_none; \
+ if (amount <= structures.size) { \
+ type_length _macro__length = structures.size - amount; \
+ f_macro_memory_structures_adjust(status, structures, type_structure, type_structures, _macro__length, type_length); \
+ } \
+ else { \
+ f_macro_memory_structures_destroy(status, structures, type_structure, type_structures); \
+ if (status == F_none) { \
+ structures.used = 0; \
+ structures.size = 0; \
+ } \
+ } \
+ } \
+ else { \
+ status = F_data_not; \
+ }
+#endif // _di_f_macro_memory_structures_decimate_by_
+
+/**
* Provide a macro for calling other macros for incrementing a buffer.
*
* If the used + step is greater than size, then increase by step_default.
--- /dev/null
+#include "string.h"
+#include "private-string.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#if !defined(_di_f_string_dynamic_adjust_)
+ f_status_t private_f_string_dynamic_adjust(const f_string_length_t length, f_string_dynamic_t *string) {
+ f_status_t status = F_none;
+
+ f_macro_string_dynamic_t_adjust(status, (*string), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_dynamic_adjust_)
+
+#if !defined(_di_f_string_append_) || !defined(_di_f_string_dynamic_append_) || !defined(_di_f_string_dynamic_mash_) || !defined(_di_f_string_mash_)
+ f_status_t private_f_string_append(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ f_status_t status = F_none;
+
+ if (destination->used + length > destination->size) {
+ status = private_f_string_dynamic_increase_by(length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ memcpy(destination->string + destination->used, source, length);
+ destination->used = destination->used + length;
+
+ return F_none;
+ }
+#endif // !defined(_di_f_string_append_) || !defined(_di_f_string_dynamic_append_) || !defined(_di_f_string_dynamic_mash_) || !defined(_di_f_string_mash_)
+
+#if !defined(_di_f_string_append_nulless_) || !defined(_di_f_string_dynamic_append_nulless_) || !defined(_di_f_string_dynamic_mash_nulless_) || !defined(_di_f_string_mash_nulless_)
+ f_status_t private_f_string_append_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+
+ if (destination->used + length > f_string_length_t_size) {
+ return F_status_set_error(F_string_too_large);
+ }
+
+ f_status_t status = F_none;
+
+ f_string_length_t i = 0;
+ f_string_length_t first = 0;
+ f_string_length_t size = 0;
+
+ for (; i < length; i++) {
+
+ if (source[i]) continue;
+
+ if (i && i > first) {
+ size = i - first;
+
+ if (destination->used + size > destination->size) {
+ status = private_f_string_dynamic_increase_by(size, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ memcpy(destination->string + destination->used, source + first, size);
+ destination->used = destination->used + size;
+ }
+
+ while (i + 1 < length && !source[i + 1]) {
+ i++;
+ } // while
+
+ first = i + 1;
+ } // for
+
+ if (i > first) {
+ size = i - first;
+
+ if (destination->used + size > destination->size) {
+ status = private_f_string_dynamic_increase_by(size, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ memcpy(destination->string + destination->used, source + first, size);
+ destination->used = destination->used + size;
+ }
+
+ return F_none;
+ }
+#endif // !defined(_di_f_string_append_nulless_) || !defined(_di_f_string_dynamic_append_nulless_) || !defined(_di_f_string_dynamic_mash_nulless_) || !defined(_di_f_string_mash_nulless_)
+
+#if !defined(_di_f_string_dynamic_decrease_) || !defined(_di_f_string_dynamic_decrease_by_) || !defined(_di_f_string_dynamic_delete_)
+ f_status_t private_f_string_dynamic_delete(f_string_dynamic_t *string) {
+ f_status_t status = F_none;
+
+ f_macro_string_dynamic_t_delete(status, (*string));
+
+ return status;
+ }
+#endif // !defined(_di_f_string_dynamic_decrease_) || !defined(_di_f_string_dynamic_decrease_by_) || !defined(_di_f_string_dynamic_delete_)
+
+#if !defined(_di_f_string_dynamic_decimate_) || !defined(_di_f_string_dynamic_decimate_by_) || !defined(_di_f_string_dynamic_delete_)
+ f_status_t private_f_string_dynamic_destroy(f_string_dynamic_t *string) {
+ f_status_t status = F_none;
+
+ f_macro_string_dynamic_t_destroy(status, (*string));
+
+ return status;
+ }
+#endif // !defined(_di_f_string_dynamic_decimate_) || !defined(_di_f_string_dynamic_decimate_by_) || !defined(_di_f_string_dynamic_delete_)
+
+#if !defined(_di_f_string_dynamic_increase_by_) || !defined(_di_f_string_append_) || !defined(_di_f_string_dynamic_append_) || !defined(_di_f_string_append_mash_) || !defined(_di_f_string_dynamic_mash_) || !defined(_di_f_string_append_nulless_) || !defined(_di_f_string_dynamic_append_nulless_) || !defined(_di_f_string_mash_nulless_) || !defined(_di_f_string_dynamic_mash_nulless_) || !defined(_di_f_string_prepend_) || !defined(_di_f_string_dynamic_prepend_) || !defined(_di_f_string_prepend_nulless_) || !defined(_di_f_string_dynamic_prepend_nulless_)
+ f_status_t private_f_string_dynamic_increase_by(const f_string_length_t amount, f_string_dynamic_t *string) {
+
+ if (string->used + amount > string->size) {
+ if (string->used + amount > f_string_length_t_size) {
+ return F_status_set_error(F_string_too_large);
+ }
+
+ return private_f_string_dynamic_resize(string->used + amount, string);
+ }
+
+ return F_none;
+ }
+#endif // !defined(_di_f_string_dynamic_increase_by_) || !defined(_di_f_string_append_) || !defined(_di_f_string_dynamic_append_) || !defined(_di_f_string_append_mash_) || !defined(_di_f_string_dynamic_mash_) || !defined(_di_f_string_append_nulless_) || !defined(_di_f_string_dynamic_append_nulless_) || !defined(_di_f_string_mash_nulless_) || !defined(_di_f_string_dynamic_mash_nulless_) || !defined(_di_f_string_prepend_) || !defined(_di_f_string_dynamic_prepend_) || !defined(_di_f_string_prepend_nulless_) || !defined(_di_f_string_dynamic_prepend_nulless_)
+
+#if !defined(_di_f_string_dynamic_decrease_) || !defined(_di_f_string_dynamic_decrease_by_) || !defined(_di_f_string_dynamic_increase_) || !defined(_di_f_string_dynamic_increase_by_) || !defined(_di_f_string_dynamic_terminate_) || !defined(_di_f_string_dynamic_terminate_after_)
+ f_status_t private_f_string_dynamic_resize(const f_string_length_t length, f_string_dynamic_t *string) {
+ f_status_t status = F_none;
+
+ f_macro_string_dynamic_t_resize(status, (*string), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_dynamic_decrease_) || !defined(_di_f_string_dynamic_decrease_by_) || !defined(_di_f_string_dynamic_increase_) || !defined(_di_f_string_dynamic_increase_by_) || !defined(_di_f_string_dynamic_terminate_) || !defined(_di_f_string_dynamic_terminate_after_)
+
+#if !defined(_di_f_string_dynamics_adjust_)
+ f_status_t private_f_string_dynamics_adjust(const f_string_length_t length, f_string_dynamics_t *strings) {
+ f_status_t status = F_none;
+
+ f_macro_string_dynamics_t_adjust(status, (*strings), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_dynamics_adjust_)
+
+#if !defined(_di_f_string_dynamics_decrease_) || !defined(_di_f_string_dynamics_decrease_by_) || !defined(_di_f_string_dynamics_delete_)
+ f_status_t private_f_string_dynamics_delete(f_string_dynamics_t *string) {
+ f_status_t status = F_none;
+
+ f_macro_string_dynamics_t_delete(status, (*string));
+
+ return status;
+ }
+#endif // !defined(_di_f_string_dynamics_decrease_) || !defined(_di_f_string_dynamics_decrease_by_) || !defined(_di_f_string_dynamics_delete_)
+
+#if !defined(_di_f_string_dynamics_decimate_) || !defined(_di_f_string_dynamics_decimate_by_) || !defined(_di_f_string_dynamics_destroy_)
+ f_status_t private_f_string_dynamics_destroy(f_string_dynamics_t *string) {
+ f_status_t status = F_none;
+
+ f_macro_string_dynamics_t_destroy(status, (*string));
+
+ return status;
+ }
+#endif // !defined(_di_f_string_dynamics_decimate_) || !defined(_di_f_string_dynamics_decimate_by_) || !defined(_di_f_string_dynamics_destroy_)
+
+#if !defined(_di_f_string_dynamics_decrease_) || !defined(_di_f_string_dynamics_decrease_by_) || !defined(_di_f_string_dynamics_increase_) || !defined(_di_f_string_dynamics_increase_by_) || !defined(_di_fl_string_dynamics_terminate_) || !defined(_di_fl_string_dynamics_terminate_after_)
+ f_status_t private_f_string_dynamics_resize(const f_string_length_t length, f_string_dynamics_t *strings) {
+ f_status_t status = F_none;
+
+ f_macro_string_dynamics_t_resize(status, (*strings), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_dynamics_decrease_) || !defined(_di_f_string_dynamics_decrease_by_) || !defined(_di_f_string_dynamics_increase_) || !defined(_di_f_string_dynamics_increase_by_) || !defined(_di_fl_string_dynamics_terminate_) || !defined(_di_fl_string_dynamics_terminate_after_)
+
+#if !defined(_di_f_string_maps_adjust_)
+ f_status_t private_f_string_maps_adjust(const f_string_length_t length, f_string_maps_t *maps) {
+ f_status_t status = F_none;
+
+ f_macro_string_maps_t_adjust(status, (*maps), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_maps_adjust_)
+
+#if !defined(f_string_maps_decrease) || !defined(f_string_maps_decrease_by) || !defined(_di_f_string_maps_delete_)
+ f_status_t private_f_string_maps_delete(f_string_maps_t *maps) {
+ f_status_t status = F_none;
+
+ f_macro_string_maps_t_delete(status, (*maps));
+
+ return status;
+ }
+#endif // !defined(f_string_maps_decrease) || !defined(f_string_maps_decrease_by) || !defined(_di_f_string_maps_delete_)
+
+#if !defined(f_string_maps_decimate) || !defined(f_string_maps_decimate_by) || !defined(_di_f_string_maps_destroy_)
+ f_status_t private_f_string_maps_destroy(f_string_maps_t *maps) {
+ f_status_t status = F_none;
+
+ f_macro_string_maps_t_destroy(status, (*maps));
+
+ return status;
+ }
+#endif // !defined(f_string_maps_decimate) || !defined(f_string_maps_decimate_by) || !defined(_di_f_string_maps_destroy_)
+
+#if !defined(_di_f_string_maps_decrease_) || !defined(_di_f_string_maps_decrease_by_) || !defined(_di_f_string_maps_increase_) || !defined(_di_f_string_maps_increase_by_) || !defined(_di_f_string_maps_terminate_) || !defined(_di_f_string_maps_terminate_after_)
+ f_status_t private_f_string_maps_resize(const f_string_length_t length, f_string_maps_t *maps) {
+ f_status_t status = F_none;
+
+ f_macro_string_maps_t_resize(status, (*maps), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_maps_decrease_) || !defined(_di_f_string_maps_decrease_by_) || !defined(_di_f_string_maps_increase_) || !defined(_di_f_string_maps_increase_by_) || !defined(_di_f_string_maps_terminate_) || !defined(_di_f_string_maps_terminate_after_)
+
+#if !defined(_di_f_string_dynamic_mish_) || !defined(_di_f_string_dynamic_partial_mish_) || !defined(_di_f_string_dynamic_partial_prepend_assure_) || !defined(_di_f_string_dynamic_partial_prepend_) || !defined(_di_f_string_dynamic_prepend_assure_) || !defined(_di_f_string_dynamic_prepend_) || !defined(_di_f_string_mish_) || !defined(_di_f_string_prepend_assure_) || !defined(_di_f_string_prepend_)
+ f_status_t private_f_string_prepend(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+
+ if (destination->used + length > f_string_length_t_size) {
+ return F_status_set_error(F_string_too_large);
+ }
+
+ if (destination->used + length > destination->size) {
+ const f_status_t status = private_f_string_dynamic_increase_by(length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ if (destination->used) {
+ memmove(destination->string + length, destination->string, destination->used);
+ memcpy(destination->string, source, length);
+ }
+ else {
+ memcpy(destination->string, source, length);
+ }
+
+ destination->used = destination->used + length;
+ return F_none;
+ }
+#endif // !defined(_di_f_string_dynamic_mish_) || !defined(_di_f_string_dynamic_partial_mish_) || !defined(_di_f_string_dynamic_partial_prepend_assure_) || !defined(_di_f_string_dynamic_partial_prepend_) || !defined(_di_f_string_dynamic_prepend_assure_) || !defined(_di_f_string_dynamic_prepend_) || !defined(_di_f_string_mish_) || !defined(_di_f_string_prepend_assure_) || !defined(_di_f_string_prepend_)
+
+#if !defined(_di_f_string_dynamic_mish_nulless_) || !defined(_di_f_string_dynamic_partial_mish_nulless_) || !defined(_di_f_string_dynamic_partial_prepend_assure_nulless_) || !defined(_di_f_string_dynamic_partial_prepend_nulless_) || !defined(_di_f_string_dynamic_prepend_assure_nulless_) || !defined(_di_f_string_dynamic_prepend_nulless_) || !defined(_di_f_string_mish_nulless_) || !defined(_di_f_string_prepend_assure_nulless_) || !defined(_di_f_string_prepend_nulless_)
+ f_status_t private_f_string_prepend_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+
+ if (destination->used + length > f_string_length_t_size) {
+ return F_status_set_error(F_string_too_large);
+ }
+
+ f_status_t status = F_none;
+
+ f_string_length_t first = 0;
+ f_string_length_t offset = 0;
+
+ f_string_length_t size = 0;
+
+ for (f_string_length_t i = 0; i <= length; i++) {
+
+ if (i == length) {
+ if (i > first) {
+ size = i - first;
+
+ if (destination->used + size > destination->size) {
+ status = private_f_string_dynamic_increase_by(size, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ memmove(destination->string + offset + size, destination->string + offset, destination->used - offset);
+ memcpy(destination->string + offset, source + first, size);
+
+ destination->used = destination->used + size;
+ offset += size;
+ }
+
+ break;
+ }
+
+ if (!source[i]) {
+ if (i > 0) {
+ if (i > first) {
+ size = i - first;
+
+ if (destination->used + size > destination->size) {
+ status = private_f_string_dynamic_increase_by(size, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ memmove(destination->string + offset + size, destination->string + offset, destination->used - offset);
+ memcpy(destination->string + offset, source + first, size);
+
+ destination->used = destination->used + size;
+ offset += size;
+ }
+ }
+
+ while (i + 1 < length && !source[i + 1]) {
+ i++;
+ } // while
+
+ first = i + 1;
+ continue;
+ }
+ } // for
+
+ return F_none;
+ }
+#endif // !defined(_di_f_string_dynamic_mish_nulless_) || !defined(_di_f_string_dynamic_partial_mish_nulless_) || !defined(_di_f_string_dynamic_partial_prepend_assure_nulless_) || !defined(_di_f_string_dynamic_partial_prepend_nulless_) || !defined(_di_f_string_dynamic_prepend_assure_nulless_) || !defined(_di_f_string_dynamic_prepend_nulless_) || !defined(_di_f_string_mish_nulless_) || !defined(_di_f_string_prepend_assure_nulless_) || !defined(_di_f_string_prepend_nulless_)
+
+#if !defined(_di_f_string_quantitys_adjust_)
+ f_status_t private_f_string_quantitys_adjust(const f_string_length_t length, f_string_quantitys_t *quantitys) {
+ f_status_t status = F_none;
+
+ f_macro_string_quantitys_t_adjust(status, (*quantitys), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_quantitys_adjust_)
+
+#if !defined(f_string_quantitys_decrease) || !defined(f_string_quantitys_decrease_by) || !defined(_di_f_string_quantitys_delete_)
+ f_status_t private_f_string_quantitys_delete(f_string_quantitys_t *quantitys) {
+ f_status_t status = F_none;
+
+ f_macro_string_quantitys_t_delete(status, (*quantitys));
+
+ return status;
+ }
+#endif // !defined(f_string_quantitys_decrease) || !defined(f_string_quantitys_decrease_by) || !defined(_di_f_string_quantitys_delete_)
+
+#if !defined(f_string_quantitys_decimate) || !defined(f_string_quantitys_decimate_by) || !defined(_di_f_string_quantitys_destroy_)
+ f_status_t private_f_string_quantitys_destroy(f_string_quantitys_t *quantitys) {
+ f_status_t status = F_none;
+
+ f_macro_string_quantitys_t_destroy(status, (*quantitys));
+
+ return status;
+ }
+#endif // !defined(f_string_quantitys_decimate) || !defined(f_string_quantitys_decimate_by) || !defined(_di_f_string_quantitys_destroy_)
+
+#if !defined(_di_f_string_quantitys_decrease_) || !defined(_di_f_string_quantitys_decrease_by_) || !defined(_di_f_string_quantitys_increase_) || !defined(_di_f_string_quantitys_increase_by_) || !defined(_di_f_string_quantitys_terminate_) || !defined(_di_f_string_quantitys_terminate_after_)
+ f_status_t private_f_string_quantitys_resize(const f_string_length_t length, f_string_quantitys_t *quantitys) {
+ f_status_t status = F_none;
+
+ f_macro_string_quantitys_t_resize(status, (*quantitys), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_quantitys_decrease_) || !defined(_di_f_string_quantitys_decrease_by_) || !defined(_di_f_string_quantitys_increase_) || !defined(_di_f_string_quantitys_increase_by_) || !defined(_di_f_string_quantitys_terminate_) || !defined(_di_f_string_quantitys_terminate_after_)
+
+#if !defined(_di_f_string_ranges_adjust_)
+ f_status_t private_f_string_ranges_adjust(const f_string_length_t length, f_string_ranges_t *ranges) {
+ f_status_t status = F_none;
+
+ f_macro_string_ranges_t_adjust(status, (*ranges), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_ranges_adjust_)
+
+#if !defined(f_string_ranges_decrease) || !defined(f_string_ranges_decrease_by) || !defined(_di_f_string_ranges_delete_)
+ f_status_t private_f_string_ranges_delete(f_string_ranges_t *ranges) {
+ f_status_t status = F_none;
+
+ f_macro_string_ranges_t_delete(status, (*ranges));
+
+ return status;
+ }
+#endif // !defined(f_string_ranges_decrease) || !defined(f_string_ranges_decrease_by) || !defined(_di_f_string_ranges_delete_)
+
+#if !defined(f_string_ranges_decimate) || !defined(f_string_ranges_decimate_by) || !defined(_di_f_string_ranges_destroy_)
+ f_status_t private_f_string_ranges_destroy(f_string_ranges_t *ranges) {
+ f_status_t status = F_none;
+
+ f_macro_string_ranges_t_destroy(status, (*ranges));
+
+ return status;
+ }
+#endif // !defined(f_string_ranges_decimate) || !defined(f_string_ranges_decimate_by) || !defined(_di_f_string_ranges_destroy_)
+
+#if !defined(_di_f_string_ranges_decrease_) || !defined(_di_f_string_ranges_decrease_by_) || !defined(_di_f_string_ranges_increase_) || !defined(_di_f_string_ranges_increase_by_) || !defined(_di_f_string_ranges_terminate_) || !defined(_di_f_string_ranges_terminate_after_)
+ f_status_t private_f_string_ranges_resize(const f_string_length_t length, f_string_ranges_t *ranges) {
+ f_status_t status = F_none;
+
+ f_macro_string_ranges_t_resize(status, (*ranges), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_ranges_decrease_) || !defined(_di_f_string_ranges_decrease_by_) || !defined(_di_f_string_ranges_increase_) || !defined(_di_f_string_ranges_increase_by_) || !defined(_di_f_string_ranges_terminate_) || !defined(_di_f_string_ranges_terminate_after_)
+
+#if !defined(_di_f_string_triples_adjust_)
+ f_status_t private_f_string_triples_adjust(const f_string_length_t length, f_string_triples_t *triples) {
+ f_status_t status = F_none;
+
+ f_macro_string_triples_t_adjust(status, (*triples), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_triples_adjust_)
+
+#if !defined(f_string_triples_decrease) || !defined(f_string_triples_decrease_by) || !defined(_di_f_string_triples_delete_)
+ f_status_t private_f_string_triples_delete(f_string_triples_t *triples) {
+ f_status_t status = F_none;
+
+ f_macro_string_triples_t_delete(status, (*triples));
+
+ return status;
+ }
+#endif // !defined(f_string_triples_decrease) || !defined(f_string_triples_decrease_by) || !defined(_di_f_string_triples_delete_)
+
+#if !defined(f_string_triples_decimate) || !defined(f_string_triples_decimate_by) || !defined(_di_f_string_triples_destroy_)
+ f_status_t private_f_string_triples_destroy(f_string_triples_t *triples) {
+ f_status_t status = F_none;
+
+ f_macro_string_triples_t_destroy(status, (*triples));
+
+ return status;
+ }
+#endif // !defined(f_string_triples_decimate) || !defined(f_string_triples_decimate_by) || !defined(_di_f_string_triples_destroy_)
+
+#if !defined(_di_f_string_triples_decrease_) || !defined(_di_f_string_triples_decrease_by_) || !defined(_di_f_string_triples_increase_) || !defined(_di_f_string_triples_increase_by_) || !defined(_di_f_string_triples_terminate_) || !defined(_di_f_string_triples_terminate_after_)
+ f_status_t private_f_string_triples_resize(const f_string_length_t length, f_string_triples_t *triples) {
+ f_status_t status = F_none;
+
+ f_macro_string_triples_t_resize(status, (*triples), length);
+
+ return status;
+ }
+#endif // !defined(_di_f_string_triples_decrease_) || !defined(_di_f_string_triples_decrease_by_) || !defined(_di_f_string_triples_increase_) || !defined(_di_f_string_triples_increase_by_) || !defined(_di_f_string_triples_terminate_) || !defined(_di_f_string_triples_terminate_after_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
--- /dev/null
+/**
+ * FLL - Level 0
+ *
+ * Project: String
+ * API Version: 0.5
+ * Licenses: lgplv2.1
+ *
+ * These are provided for internal reduction in redundant code.
+ * These should not be exposed/used outside of this project.
+ */
+#ifndef _PRIVATE_F_string_h
+#define _PRIVATE_F_string_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param string
+ * The string to adjust.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_adjust().
+ *
+ * @see f_macro_string_dynamic_t_adjust()
+ * @see f_string_dynamic_adjust()
+ */
+#if !defined(_di_f_string_dynamic_adjust_)
+ extern f_status_t private_f_string_dynamic_adjust(const f_string_length_t length, f_string_dynamic_t *string) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamic_adjust_)
+
+/**
+ * Private implementation of f_string_append().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param source
+ * The source string to append.
+ * @param length
+ * Length of source to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
+ *
+ * @see memcpy()
+ *
+ * @see f_macro_string_dynamic_t_resize()
+ * @see f_string_append()
+ * @see f_string_dynamic_append()
+ * @see f_string_dynamic_mash()
+ * @see f_string_mash()
+ */
+#if !defined(_di_f_string_append_) || !defined(_di_f_string_dynamic_append_) || !defined(_di_f_string_dynamic_mash_) || !defined(_di_f_string_mash_)
+ extern f_status_t private_f_string_append(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_append_) || !defined(_di_f_string_dynamic_append_) || !defined(_di_f_string_dynamic_mash_) || !defined(_di_f_string_mash_)
+
+/**
+ * Private implementation of f_string_append_nulless().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param source
+ * The source string to append.
+ * @param length
+ * Length of source to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
+ *
+ * @see memcpy()
+ *
+ * @see f_macro_string_dynamic_t_resize()
+ * @see f_string_append_nulless()
+ * @see f_string_dynamic_append_nulless()
+ * @see f_string_dynamic_mash_nulless()
+ * @see f_string_mash_nulless()
+ */
+#if !defined(_di_f_string_append_nulless_) || !defined(_di_f_string_dynamic_append_nulless_) || !defined(_di_f_string_dynamic_mash_nulless_) || !defined(_di_f_string_mash_nulless_)
+ extern f_status_t private_f_string_append_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_append_nulless_) || !defined(_di_f_string_dynamic_append_nulless_) || !defined(_di_f_string_dynamic_mash_nulless_) || !defined(_di_f_string_mash_nulless_)
+
+/**
+ * Private implementation of f_string_dynamic_delete().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param string
+ * The string to delete.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_delete().
+ *
+ * @see f_string_dynamic_decrease()
+ * @see f_string_dynamic_decrease_by()
+ * @see f_string_dynamic_delete()
+ */
+#if !defined(_di_f_string_dynamic_decrease_) || !defined(_di_f_string_dynamic_decrease_by_) || !defined(_di_f_string_dynamic_delete_)
+ extern f_status_t private_f_string_dynamic_delete(f_string_dynamic_t *string) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamic_decrease_) || !defined(_di_f_string_dynamic_decrease_by_) || !defined(_di_f_string_dynamic_delete_)
+
+/**
+ * Private implementation of f_string_dynamic_destroy().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param string
+ * The string to destroy.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_destroy().
+ *
+ * @see f_string_dynamic_decimate()
+ * @see f_string_dynamic_decimate_by()
+ * @see f_string_dynamic_destroy()
+ */
+#if !defined(_di_f_string_dynamic_decimate_) || !defined(_di_f_string_dynamic_decimate_by_) || !defined(_di_f_string_dynamic_destroy_)
+ extern f_status_t private_f_string_dynamic_destroy(f_string_dynamic_t *string) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamic_decimate_) || !defined(_di_f_string_dynamic_decimate_by_) || !defined(_di_f_string_dynamic_destroy_)
+
+/**
+ * Private implementation of f_string_dynamic_increase_by().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param amount
+ * A positive number representing how much to increase the size by.
+ * @param string
+ * The string to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
+ *
+ * @see memcpy()
+ *
+ * @see f_string_append()
+ * @see f_string_append_mash()
+ * @see f_string_append_nulless()
+ * @see f_string_dynamic_append()
+ * @see f_string_dynamic_append_nulless()
+ * @see f_string_dynamic_increase_by()
+ * @see f_string_dynamic_mash()
+ * @see f_string_dynamic_mash_nulless()
+ * @see f_string_dynamic_prepend()
+ * @see f_string_dynamic_prepend_nulless()
+ * @see f_string_mash_nulless()
+ * @see f_string_prepend()
+ * @see f_string_prepend_nulless()
+ */
+#if !defined(_di_f_string_dynamic_increase_by_) || !defined(_di_f_string_append_) || !defined(_di_f_string_dynamic_append_) || !defined(_di_f_string_append_mash_) || !defined(_di_f_string_dynamic_mash_) || !defined(_di_f_string_append_nulless_) || !defined(_di_f_string_dynamic_append_nulless_) || !defined(_di_f_string_mash_nulless_) || !defined(_di_f_string_dynamic_mash_nulless_) || !defined(_di_f_string_prepend_) || !defined(_di_f_string_dynamic_prepend_) || !defined(_di_f_string_prepend_nulless_) || !defined(_di_f_string_dynamic_prepend_nulless_)
+ extern f_status_t private_f_string_dynamic_increase_by(const f_string_length_t amount, f_string_dynamic_t *string) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamic_increase_by_) || !defined(_di_f_string_append_) || !defined(_di_f_string_dynamic_append_) || !defined(_di_f_string_append_mash_) || !defined(_di_f_string_dynamic_mash_) || !defined(_di_f_string_append_nulless_) || !defined(_di_f_string_dynamic_append_nulless_) || !defined(_di_f_string_mash_nulless_) || !defined(_di_f_string_dynamic_mash_nulless_) || !defined(_di_f_string_prepend_) || !defined(_di_f_string_dynamic_prepend_) || !defined(_di_f_string_prepend_nulless_) || !defined(_di_f_string_dynamic_prepend_nulless_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param string
+ * The string to resize.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
+ *
+ * @see f_macro_string_dynamic_t_resize()
+ * @see f_string_dynamic_decrease()
+ * @see f_string_dynamic_decrease_by()
+ * @see f_string_dynamic_increase()
+ * @see f_string_dynamic_increase_by()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamic_terminate_after()
+ */
+#if !defined(_di_f_string_dynamic_decrease_) || !defined(_di_f_string_dynamic_decrease_by_) || !defined(_di_f_string_dynamic_increase_) || !defined(_di_f_string_dynamic_increase_by_) || !defined(_di_f_string_dynamic_terminate_) || !defined(_di_f_string_dynamic_terminate_after_)
+ extern f_status_t private_f_string_dynamic_resize(const f_string_length_t length, f_string_dynamic_t *string) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamic_decrease_) || !defined(_di_f_string_dynamic_decrease_by_) || !defined(_di_f_string_dynamic_increase_) || !defined(_di_f_string_dynamic_increase_by_) || !defined(_di_f_string_dynamic_terminate_) || !defined(_di_f_string_dynamic_terminate_after_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param strings
+ * The strings to adjust.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamics_t_adjust().
+ *
+ * @see f_macro_string_dynamics_t_adjust()
+ * @see f_string_dynamics_adjust()
+ */
+#if !defined(_di_f_string_dynamics_adjust_)
+ extern f_status_t private_f_string_dynamics_adjust(const f_string_length_t length, f_string_dynamics_t *strings) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamics_adjust_)
+
+/**
+ * Private implementation of f_string_dynamics_delete().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param strings
+ * The strings to delete.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamics_t_delete().
+ *
+ * @see f_string_dynamics_decrease()
+ * @see f_string_dynamics_decrease_by()
+ * @see f_string_dynamics_delete()
+ */
+#if !defined(_di_f_string_dynamics_decrease_) || !defined(_di_f_string_dynamics_decrease_by_) || !defined(_di_f_string_dynamics_delete_)
+ extern f_status_t private_f_string_dynamics_delete(f_string_dynamics_t *strings) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamics_decrease_) || !defined(_di_f_string_dynamics_decrease_by_) || !defined(_di_f_string_dynamics_delete_)
+
+/**
+ * Private implementation of f_string_dynamics_destroy().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param strings
+ * The strings to delete.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamics_t_destroy().
+ *
+ * @see f_string_dynamics_decimate()
+ * @see f_string_dynamics_decimate_by()
+ * @see f_string_dynamics_destroy()
+ */
+#if !defined(_di_f_string_dynamics_decimate_) || !defined(_di_f_string_dynamics_decimate_by_) || !defined(_di_f_string_dynamics_delete_)
+ extern f_status_t private_f_string_dynamics_destroy(f_string_dynamics_t *strings) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamics_decimate_) || !defined(_di_f_string_dynamics_decimate_by_) || !defined(_di_f_string_dynamics_delete_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param strings
+ * The strings to resize.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamics_t_resize().
+ *
+ * @see f_macro_string_dynamics_t_resize()
+ * @see f_string_dynamics_decrease()
+ * @see f_string_dynamics_decrease_by()
+ * @see f_string_dynamics_increase()
+ * @see f_string_dynamics_increase_by()
+ * @see fl_string_dynamics_terminate()
+ * @see fl_string_dynamics_terminate_after()
+ */
+#if !defined(_di_f_string_dynamics_decrease_) || !defined(_di_f_string_dynamics_decrease_by_) || !defined(_di_f_string_dynamics_increase_) || !defined(_di_f_string_dynamics_increase_by_) || !defined(_di_fl_string_dynamics_terminate_) || !defined(_di_fl_string_dynamics_terminate_after_)
+ extern f_status_t private_f_string_dynamics_resize(const f_string_length_t length, f_string_dynamics_t *strings) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamics_decrease_) || !defined(_di_f_string_dynamics_decrease_by_) || !defined(_di_f_string_dynamics_increase_) || !defined(_di_f_string_dynamics_increase_by_) || !defined(_di_fl_string_dynamics_terminate_) || !defined(_di_fl_string_dynamics_terminate_after_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param maps
+ * The maps to adjust.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_maps_t_adjust().
+ *
+ * @see f_macro_string_maps_t_adjust()
+ * @see f_string_maps_adjust()
+ */
+#if !defined(_di_f_string_maps_adjust_)
+ extern f_status_t private_f_string_maps_adjust(const f_string_length_t length, f_string_maps_t *maps) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_maps_adjust_)
+
+/**
+ * Private implementation of f_string_maps_delete().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param maps
+ * The maps to delete.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_maps_t_delete().
+ *
+ * @see f_string_maps_decrease()
+ * @see f_string_maps_decrease_by()
+ * @see f_string_maps_delete()
+ */
+#if !defined(f_string_maps_decrease) || !defined(f_string_maps_decrease_by) || !defined(_di_f_string_maps_delete_)
+ extern f_status_t private_f_string_maps_delete(f_string_maps_t *maps) f_gcc_attribute_visibility_internal;
+#endif // !defined(f_string_maps_decrease) || !defined(f_string_maps_decrease_by) || !defined(_di_f_string_maps_delete_)
+
+/**
+ * Private implementation of f_string_maps_destroy().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param maps
+ * The maps to destroy.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_maps_t_destroy().
+ *
+ * @see f_string_maps_decimate()
+ * @see f_string_maps_decimate_by()
+ * @see f_string_maps_destroy()
+ */
+#if !defined(f_string_maps_decimate) || !defined(f_string_maps_decimate_by) || !defined(_di_f_string_maps_destroy_)
+ extern f_status_t private_f_string_maps_destroy(f_string_maps_t *maps) f_gcc_attribute_visibility_internal;
+#endif // !defined(f_string_maps_decimate) || !defined(f_string_maps_decimate_by) || !defined(_di_f_string_maps_destroy_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param maps
+ * The maps to resize.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_maps_t_resize().
+ *
+ * @see f_macro_string_dynamic_t_resize()
+ * @see f_string_maps_decrease()
+ * @see f_string_maps_decrease_by()
+ * @see f_string_maps_increase()
+ * @see f_string_maps_increase_by()
+ * @see f_string_maps_terminate()
+ * @see f_string_maps_terminate_after()
+ */
+#if !defined(_di_f_string_maps_decrease_) || !defined(_di_f_string_maps_decrease_by_) || !defined(_di_f_string_maps_increase_) || !defined(_di_f_string_maps_increase_by_) || !defined(_di_f_string_maps_terminate_) || !defined(_di_f_string_maps_terminate_after_)
+ extern f_status_t private_f_string_maps_resize(const f_string_length_t length, f_string_maps_t *maps) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_maps_decrease_) || !defined(_di_f_string_maps_decrease_by_) || !defined(_di_f_string_maps_increase_) || !defined(_di_f_string_maps_increase_by_) || !defined(_di_f_string_maps_terminate_) || !defined(_di_f_string_maps_terminate_after_)
+
+/**
+ * Private implementation of f_string_prepend().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param length
+ * Length of source to append.
+ * @param destination
+ * The destination string the source and glue are prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
+ *
+ * @see memcopy()
+ * @see memmove()
+ *
+ * @see f_string_dynamic_mish()
+ * @see f_string_dynamic_partial_mish()
+ * @see f_string_dynamic_partial_prepend_assure()
+ * @see f_string_dynamic_partial_prepend()
+ * @see f_string_dynamic_prepend_assure()
+ * @see f_string_dynamic_prepend()
+ * @see f_string_mish()
+ * @see f_string_prepend_assure()
+ * @see f_string_prepend()
+ */
+#if !defined(_di_f_string_dynamic_mish_) || !defined(_di_f_string_dynamic_partial_mish_) || !defined(_di_f_string_dynamic_partial_prepend_assure_) || !defined(_di_f_string_dynamic_partial_prepend_) || !defined(_di_f_string_dynamic_prepend_assure_) || !defined(_di_f_string_dynamic_prepend_) || !defined(_di_f_string_mish_) || !defined(_di_f_string_prepend_assure_) || !defined(_di_f_string_prepend_)
+ extern f_status_t private_f_string_prepend(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamic_mish_) || !defined(_di_f_string_dynamic_partial_mish_) || !defined(_di_f_string_dynamic_partial_prepend_assure_) || !defined(_di_f_string_dynamic_partial_prepend_) || !defined(_di_f_string_dynamic_prepend_assure_) || !defined(_di_f_string_dynamic_prepend_) || !defined(_di_f_string_mish_) || !defined(_di_f_string_prepend_assure_) || !defined(_di_f_string_prepend_)
+
+/**
+ * Private implementation of f_string_prepend_nulless().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param length
+ * Length of source to append.
+ * @param destination
+ * The destination string the source and glue are prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ *
+ * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
+ *
+ * @see memcopy()
+ * @see memmove()
+ *
+ * @see f_string_dynamic_mish_nulless()
+ * @see f_string_dynamic_partial_mish_nulless()
+ * @see f_string_dynamic_partial_prepend_assure_nulless()
+ * @see f_string_dynamic_partial_prepend_nulless()
+ * @see f_string_dynamic_prepend_assure_nulless()
+ * @see f_string_dynamic_prepend_nulless()
+ * @see f_string_mish_nulless()
+ * @see f_string_prepend_assure_nulless()
+ * @see f_string_prepend_nulless()
+ */
+#if !defined(_di_f_string_dynamic_mish_nulless_) || !defined(_di_f_string_dynamic_partial_mish_nulless_) || !defined(_di_f_string_dynamic_partial_prepend_assure_nulless_) || !defined(_di_f_string_dynamic_partial_prepend_nulless_) || !defined(_di_f_string_dynamic_prepend_assure_nulless_) || !defined(_di_f_string_dynamic_prepend_nulless_) || !defined(_di_f_string_mish_nulless_) || !defined(_di_f_string_prepend_assure_nulless_) || !defined(_di_f_string_prepend_nulless_)
+ extern f_status_t private_f_string_prepend_nulless(const f_string_t source, f_string_length_t length, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_dynamic_mish_nulless_) || !defined(_di_f_string_dynamic_partial_mish_nulless_) || !defined(_di_f_string_dynamic_partial_prepend_assure_nulless_) || !defined(_di_f_string_dynamic_partial_prepend_nulless_) || !defined(_di_f_string_dynamic_prepend_assure_nulless_) || !defined(_di_f_string_dynamic_prepend_nulless_) || !defined(_di_f_string_mish_nulless_) || !defined(_di_f_string_prepend_assure_nulless_) || !defined(_di_f_string_prepend_nulless_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param quantitys
+ * The quantitys to adjust.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_quantitys_t_adjust().
+ *
+ * @see f_macro_string_quantitys_t_adjust()
+ * @see f_string_quantitys_adjust()
+ */
+#if !defined(_di_f_string_quantitys_adjust_)
+ extern f_status_t private_f_string_quantitys_adjust(const f_string_length_t length, f_string_quantitys_t *quantitys) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_quantitys_adjust_)
+
+/**
+ * Private implementation of f_string_quantitys_delete().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param quantitys
+ * The quantitys to delete.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_quantitys_t_delete().
+ *
+ * @see f_string_quantitys_decrease()
+ * @see f_string_quantitys_decrease_by()
+ * @see f_string_quantitys_delete()
+ */
+#if !defined(f_string_quantitys_decrease) || !defined(f_string_quantitys_decrease_by) || !defined(_di_f_string_quantitys_delete_)
+ extern f_status_t private_f_string_quantitys_delete(f_string_quantitys_t *quantitys) f_gcc_attribute_visibility_internal;
+#endif // !defined(f_string_quantitys_decrease) || !defined(f_string_quantitys_decrease_by) || !defined(_di_f_string_quantitys_delete_)
+
+/**
+ * Private implementation of f_string_quantitys_destroy().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param quantitys
+ * The quantitys to destroy.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_quantitys_t_destroy().
+ *
+ * @see f_string_quantitys_decimate()
+ * @see f_string_quantitys_decimate_by()
+ * @see f_string_quantitys_destroy()
+ */
+#if !defined(f_string_quantitys_decimate) || !defined(f_string_quantitys_decimate_by) || !defined(_di_f_string_quantitys_destroy_)
+ extern f_status_t private_f_string_quantitys_destroy(f_string_quantitys_t *quantitys) f_gcc_attribute_visibility_internal;
+#endif // !defined(f_string_quantitys_decimate) || !defined(f_string_quantitys_decimate_by) || !defined(_di_f_string_quantitys_destroy_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param quantitys
+ * The quantitys to resize.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_quantitys_t_resize().
+ *
+ * @see f_macro_string_dynamic_t_resize()
+ * @see f_string_quantitys_decrease()
+ * @see f_string_quantitys_decrease_by()
+ * @see f_string_quantitys_increase()
+ * @see f_string_quantitys_increase_by()
+ * @see f_string_quantitys_terminate()
+ * @see f_string_quantitys_terminate_after()
+ */
+#if !defined(_di_f_string_quantitys_decrease_) || !defined(_di_f_string_quantitys_decrease_by_) || !defined(_di_f_string_quantitys_increase_) || !defined(_di_f_string_quantitys_increase_by_) || !defined(_di_f_string_quantitys_terminate_) || !defined(_di_f_string_quantitys_terminate_after_)
+ extern f_status_t private_f_string_quantitys_resize(const f_string_length_t length, f_string_quantitys_t *quantitys) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_quantitys_decrease_) || !defined(_di_f_string_quantitys_decrease_by_) || !defined(_di_f_string_quantitys_increase_) || !defined(_di_f_string_quantitys_increase_by_) || !defined(_di_f_string_quantitys_terminate_) || !defined(_di_f_string_quantitys_terminate_after_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param ranges
+ * The ranges to adjust.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_ranges_t_adjust().
+ *
+ * @see f_macro_string_ranges_t_adjust()
+ * @see f_string_ranges_adjust()
+ */
+#if !defined(_di_f_string_ranges_adjust_)
+ extern f_status_t private_f_string_ranges_adjust(const f_string_length_t length, f_string_ranges_t *ranges) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_ranges_adjust_)
+
+/**
+ * Private implementation of f_string_ranges_delete().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param ranges
+ * The ranges to delete.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_ranges_t_delete().
+ *
+ * @see f_string_ranges_decrease()
+ * @see f_string_ranges_decrease_by()
+ * @see f_string_ranges_delete()
+ */
+#if !defined(f_string_ranges_decrease) || !defined(f_string_ranges_decrease_by) || !defined(_di_f_string_ranges_delete_)
+ extern f_status_t private_f_string_ranges_delete(f_string_ranges_t *ranges) f_gcc_attribute_visibility_internal;
+#endif // !defined(f_string_ranges_decrease) || !defined(f_string_ranges_decrease_by) || !defined(_di_f_string_ranges_delete_)
+
+/**
+ * Private implementation of f_string_ranges_destroy().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param ranges
+ * The ranges to destroy.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_ranges_t_destroy().
+ *
+ * @see f_string_ranges_decimate()
+ * @see f_string_ranges_decimate_by()
+ * @see f_string_ranges_destroy()
+ */
+#if !defined(f_string_ranges_decimate) || !defined(f_string_ranges_decimate_by) || !defined(_di_f_string_ranges_destroy_)
+ extern f_status_t private_f_string_ranges_destroy(f_string_ranges_t *ranges) f_gcc_attribute_visibility_internal;
+#endif // !defined(f_string_ranges_decimate) || !defined(f_string_ranges_decimate_by) || !defined(_di_f_string_ranges_destroy_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param ranges
+ * The ranges to resize.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_ranges_t_resize().
+ *
+ * @see f_macro_string_dynamic_t_resize()
+ * @see f_string_ranges_decrease()
+ * @see f_string_ranges_decrease_by()
+ * @see f_string_ranges_increase()
+ * @see f_string_ranges_increase_by()
+ * @see f_string_ranges_terminate()
+ * @see f_string_ranges_terminate_after()
+ */
+#if !defined(_di_f_string_ranges_decrease_) || !defined(_di_f_string_ranges_decrease_by_) || !defined(_di_f_string_ranges_increase_) || !defined(_di_f_string_ranges_increase_by_) || !defined(_di_f_string_ranges_terminate_) || !defined(_di_f_string_ranges_terminate_after_)
+ extern f_status_t private_f_string_ranges_resize(const f_string_length_t length, f_string_ranges_t *ranges) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_ranges_decrease_) || !defined(_di_f_string_ranges_decrease_by_) || !defined(_di_f_string_ranges_increase_) || !defined(_di_f_string_ranges_increase_by_) || !defined(_di_f_string_ranges_terminate_) || !defined(_di_f_string_ranges_terminate_after_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param triples
+ * The triples to adjust.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_triples_t_adjust().
+ *
+ * @see f_macro_string_triples_t_adjust()
+ * @see f_string_triples_adjust()
+ */
+#if !defined(_di_f_string_triples_adjust_)
+ extern f_status_t private_f_string_triples_adjust(const f_string_length_t length, f_string_triples_t *triples) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_triples_adjust_)
+
+/**
+ * Private implementation of f_string_triples_delete().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param triples
+ * The triples to delete.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_triples_t_delete().
+ *
+ * @see f_string_triples_decrease()
+ * @see f_string_triples_decrease_by()
+ * @see f_string_triples_delete()
+ */
+#if !defined(f_string_triples_decrease) || !defined(f_string_triples_decrease_by) || !defined(_di_f_string_triples_delete_)
+ extern f_status_t private_f_string_triples_delete(f_string_triples_t *triples) f_gcc_attribute_visibility_internal;
+#endif // !defined(f_string_triples_decrease) || !defined(f_string_triples_decrease_by) || !defined(_di_f_string_triples_delete_)
+
+/**
+ * Private implementation of f_string_triples_destroy().
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param triples
+ * The triples to destroy.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_triples_t_destroy().
+ *
+ * @see f_string_triples_decimate()
+ * @see f_string_triples_decimate_by()
+ * @see f_string_triples_destroy()
+ */
+#if !defined(f_string_triples_decimate) || !defined(f_string_triples_decimate_by) || !defined(_di_f_string_triples_destroy_)
+ extern f_status_t private_f_string_triples_destroy(f_string_triples_t *triples) f_gcc_attribute_visibility_internal;
+#endif // !defined(f_string_triples_decimate) || !defined(f_string_triples_decimate_by) || !defined(_di_f_string_triples_destroy_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ * The new size to use.
+ * @param triples
+ * The triples to resize.
+ *
+ * @return
+ * F_none on success.
+ *
+ * Errors (with error bit) from: f_macro_string_triples_t_resize().
+ *
+ * @see f_macro_string_dynamic_t_resize()
+ * @see f_string_triples_decrease()
+ * @see f_string_triples_decrease_by()
+ * @see f_string_triples_increase()
+ * @see f_string_triples_increase_by()
+ * @see f_string_triples_terminate()
+ * @see f_string_triples_terminate_after()
+ */
+#if !defined(_di_f_string_triples_decrease_) || !defined(_di_f_string_triples_decrease_by_) || !defined(_di_f_string_triples_increase_) || !defined(_di_f_string_triples_increase_by_) || !defined(_di_f_string_triples_terminate_) || !defined(_di_f_string_triples_terminate_after_)
+ extern f_status_t private_f_string_triples_resize(const f_string_length_t length, f_string_triples_t *triples) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_f_string_triples_decrease_) || !defined(_di_f_string_triples_decrease_by_) || !defined(_di_f_string_triples_increase_) || !defined(_di_f_string_triples_increase_by_) || !defined(_di_f_string_triples_terminate_) || !defined(_di_f_string_triples_terminate_after_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _PRIVATE_F_string_h
#include "string.h"
+#include "private-string.h"
#ifdef __cplusplus
extern "C" {
const f_string_t f_string_ascii_slash_forward_s = f_string_ascii_slash_forward;
const f_string_t f_string_ascii_slash_backward_s = f_string_ascii_slash_backward;
const f_string_t f_string_ascii_tilde_s = f_string_ascii_tilde;
-
#endif // _di_string_ascii_s_
#ifdef __cplusplus
#define f_macro_string_lengthss_t_delete_simple(lengthss) f_macro_memory_structures_delete_simple(lengthss, f_string_length_t, f_string_lengths_t);
#define f_macro_string_lengthss_t_destroy_simple(lengthss) f_macro_memory_structures_destroy_simple(lengthss, f_string_length_t, f_string_lengths_t);
+
+ #define f_macro_string_lengthss_t_increase(status, string_lengths) f_macro_memory_structures_increase(status, string_lengths, f_string_length_t, f_array_length_t);
+ #define f_macro_string_lengthss_t_decrease(status, string_lengths) f_macro_memory_structures_decrease(status, string_lengths, f_string_length_t, f_string_lengths_t);
+ #define f_macro_string_lengthss_t_decimate(status, string_lengths) f_macro_memory_structures_decimate(status, string_lengths, f_string_length_t, f_string_lengths_t);
+
+ #define f_macro_string_lengthss_t_increase_by(status, string_lengths, amount) f_macro_memory_structures_increase_by(status, string_lengths, f_string_length_t, f_array_length_t, amount);
+ #define f_macro_string_lengthss_t_decrease_by(status, string_lengths, amount) f_macro_memory_structures_decrease_by(status, string_lengths, f_string_length_t, f_string_lengths_t, f_array_length_t, amount);
+ #define f_macro_string_lengthss_t_decimate_by(status, string_lengths, amount) f_macro_memory_structures_decimate_by(status, string_lengths, f_string_length_t, f_string_lengths_t, f_array_length_t, amount);
#endif // _di_f_string_lengthss_t_
/**
#include "string.h"
+#include "private-string.h"
#ifdef __cplusplus
extern "C" {
#endif
-#ifndef _di_f_string_static_empty_s_
- const f_string_static_t f_string_static_empty_s = f_macro_string_static_t_initialize("", 0);
-#endif // _di_f_string_static_empty_s_
+#ifndef _di_f_string_append_
+ f_status_t f_string_append(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ return private_f_string_append(source, length, destination);
+ }
+#endif // _di_f_string_append_
+
+#ifndef _di_f_string_append_assure_
+ f_status_t f_string_append_assure(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+ if (destination->used < length) return private_f_string_append(source, length, destination);
+
+ f_string_length_t i = 1;
+ f_string_length_t j = 1;
+
+ while (i <= length && j <= destination->used) {
+ if (!source[length - i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[destination->used - j]) {
+ j++;
+ continue;
+ }
+
+ if (source[length - i] != destination->string[destination->used - j]) {
+ return private_f_string_append(source, length, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_append_assure_
+
+#ifndef _di_f_string_append_assure_nulless_
+ f_status_t f_string_append_assure_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ if (destination->used < length) {
+ return private_f_string_append_nulless(source, length, destination);
+ }
+
+ f_string_length_t i = 1;
+ f_string_length_t j = 1;
+
+ while (i <= length && j <= destination->used) {
+ if (!source[length - i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[destination->used - j]) {
+ j++;
+ continue;
+ }
+
+ if (source[length - i] != destination->string[destination->used - j]) {
+ return private_f_string_append_nulless(source, length, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_append_assure_nulless_
+
+#ifndef _di_f_string_append_nulless_
+ f_status_t f_string_append_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ return private_f_string_append_nulless(source, length, destination);
+ }
+#endif // _di_f_string_append_nulless_
+
+#ifndef _di_f_string_dynamic_append_
+ f_status_t f_string_dynamic_append(const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ return private_f_string_append(source.string, source.used, destination);
+ }
+#endif // _di_f_string_dynamic_append_
+
+#ifndef _di_f_string_dynamic_append_assure_
+ f_status_t f_string_dynamic_append_assure(const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ if (destination->used < source.used) {
+ return private_f_string_append(source.string, source.used, destination);
+ }
+
+ f_string_length_t i = 1;
+ f_string_length_t j = 1;
+
+ while (i <= source.used && j <= destination->used) {
+ if (!source.string[source.used - i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[destination->used - j]) {
+ j++;
+ continue;
+ }
+
+ if (source.string[source.used - i] != destination->string[destination->used - j]) {
+ return private_f_string_append(source.string, source.used, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_append_assure_
+
+#ifndef _di_f_string_dynamic_append_assure_nulless_
+ f_status_t f_string_dynamic_append_assure_nulless(const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ if (destination->used < source.used) {
+ return private_f_string_append_nulless(source.string, source.used, destination);
+ }
+
+ f_string_length_t i = 1;
+ f_string_length_t j = 1;
+
+ while (i <= source.used && j <= destination->used) {
+ if (!source.string[source.used - i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[destination->used - j]) {
+ j++;
+ continue;
+ }
+
+ if (source.string[source.used - i] != destination->string[destination->used - j]) {
+ return private_f_string_append_nulless(source.string, source.used, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_append_assure_nulless_
+
+#ifndef _di_f_string_dynamic_append_nulless_
+ f_status_t f_string_dynamic_append_nulless(const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ return private_f_string_append_nulless(source.string, source.used, destination);
+ }
+#endif // _di_f_string_dynamic_append_nulless_
+
+#ifndef _di_f_string_dynamic_mash_
+ f_status_t f_string_dynamic_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ if (glue_length && destination->used) {
+ const f_status_t status = private_f_string_append(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_append(source.string, source.used, destination);
+ }
+#endif // _di_f_string_dynamic_mash_
+
+#ifndef _di_f_string_dynamic_mash_nulless_
+ f_status_t f_string_dynamic_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ if (glue_length && destination->used) {
+ const f_status_t status = private_f_string_append_nulless(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_append_nulless(source.string, source.used, destination);
+ }
+#endif // _di_f_string_dynamic_mash_nulless_
+
+#ifndef _di_f_string_dynamic_mish_
+ f_status_t f_string_dynamic_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ if (glue_length && destination->used) {
+ const f_status_t status = private_f_string_prepend(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_prepend(source.string, source.used, destination);
+ }
+#endif // _di_f_string_dynamic_mish_
+
+#ifndef _di_f_string_dynamic_mish_nulless_
+ f_status_t f_string_dynamic_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ if (glue_length && destination->used) {
+ const f_status_t status = private_f_string_prepend_nulless(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_prepend_nulless(source.string, source.used, destination);
+ }
+#endif // _di_f_string_dynamic_mish_nulless_
+
+#ifndef _di_f_string_dynamic_partial_append_
+ f_status_t f_string_dynamic_partial_append(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ return private_f_string_append(source.string + range.start, (range.stop - range.start) + 1, destination);
+ }
+#endif // _di_f_string_dynamic_partial_append_
+
+#ifndef _di_f_string_dynamic_partial_append_assure_
+ f_status_t f_string_dynamic_partial_append_assure(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ const f_string_length_t length = (range.stop - range.start) + 1;
+
+ if (destination->used < length) {
+ return private_f_string_append(source.string + range.start, length, destination);
+ }
+
+ f_string_length_t i = 1;
+ f_string_length_t j = 1;
+
+ while (i <= length && j <= destination->used) {
+ if (!source.string[range.stop - i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[destination->used - j]) {
+ j++;
+ continue;
+ }
+
+ if (source.string[range.stop - i] != destination->string[destination->used - j]) {
+ return private_f_string_append(source.string + range.start, length, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+ }
+#endif // _di_f_string_dynamic_partial_append_assure_
+
+#ifndef _di_f_string_dynamic_partial_append_assure_nulless_
+ f_status_t f_string_dynamic_partial_append_assure_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ const f_string_length_t length = (range.stop - range.start) + 1;
+
+ if (destination->used < length) {
+ return private_f_string_append_nulless(source.string + range.start, length, destination);
+ }
+
+ f_string_length_t i = 1;
+ f_string_length_t j = 1;
+
+ while (i <= length && j <= destination->used) {
+ if (!source.string[range.stop - i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[destination->used - j]) {
+ j++;
+ continue;
+ }
+
+ if (source.string[range.stop - i] != destination->string[destination->used - j]) {
+ return private_f_string_append_nulless(source.string + range.start, length, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+ }
+#endif // _di_f_string_dynamic_append_assure_nulless_
+
+#ifndef _di_f_string_dynamic_partial_append_nulless_
+ f_status_t f_string_dynamic_partial_append_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ return private_f_string_append_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
+ }
+#endif // _di_f_string_dynamic_partial_append_nulless_
+
+#ifndef _di_f_string_dynamic_partial_mash_
+ f_status_t f_string_dynamic_partial_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ if (glue_length && destination->used) {
+ f_status_t status = private_f_string_append(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_append(source.string + range.start, (range.stop - range.start) + 1, destination);
+ }
+#endif // _di_f_string_dynamic_partial_mash_
+
+#ifndef _di_f_string_dynamic_partial_mash_nulless_
+ f_status_t f_string_dynamic_partial_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ if (glue_length && destination->used) {
+ f_status_t status = private_f_string_append_nulless(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_append_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
+ }
+#endif // _di_f_string_dynamic_partial_mash_nulless_
+
+#ifndef _di_f_string_dynamic_partial_mish_
+ f_status_t fl_string_partial_dynamic_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ if (glue_length && destination->used) {
+ f_status_t status = private_f_string_prepend(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_prepend(source.string + range.start, (range.stop - range.start) + 1, destination);
+ }
+#endif // _di_f_string_dynamic_partial_mish_
+
+#ifndef _di_f_string_dynamic_partial_mish_nulless_
+ f_status_t f_string_dynamic_partial_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ if (glue_length && destination->used) {
+ f_status_t status = private_f_string_prepend_nulless(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_prepend_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
+ }
+#endif // _di_f_string_dynamic_partial_mish_nulless_
+
+#ifndef _di_f_string_dynamic_partial_prepend_
+ f_status_t f_string_dynamic_partial_prepend(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ return private_f_string_prepend(source.string + range.start, (range.stop - range.start) + 1, destination);
+ }
+#endif // _di_f_string_dynamic_partial_prepend_
+
+#ifndef _di_f_string_dynamic_partial_prepend_assure_
+ f_status_t f_string_dynamic_partial_prepend_assure(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ const f_string_length_t length = (range.stop - range.start) + 1;
+
+ if (destination->used < length) {
+ return private_f_string_prepend(source.string + range.start, length, destination);
+ }
+
+ f_string_length_t i = 0;
+ f_string_length_t j = 0;
+
+ while (i < length && j < destination->used) {
+ if (!source.string[i + range.start]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[j]) {
+ j++;
+ continue;
+ }
+
+ if (source.string[i + range.start] != destination->string[i]) {
+ return private_f_string_prepend(source.string + range.start, length, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_partial_prepend_assure_
+
+#ifndef _di_f_string_dynamic_partial_prepend_assure_nulless_
+ f_status_t f_string_dynamic_partial_prepend_assure_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ const f_string_length_t length = (range.stop - range.start) + 1;
+
+ if (destination->used < length) {
+ return private_f_string_prepend_nulless(source.string + range.start, length, destination);
+ }
+
+ f_string_length_t i = 0;
+ f_string_length_t j = 0;
+
+ while (i < length && j < destination->used) {
+ if (!source.string[i + range.start]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[j]) {
+ j++;
+ continue;
+ }
+
+ if (source.string[i + range.start] != destination->string[i]) {
+ return private_f_string_prepend_nulless(source.string + range.start, length, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_partial_prepend_assure_nulless
+
+#ifndef _di_f_string_dynamic_partial_prepend_nulless_
+ f_status_t f_string_dynamic_partial_prepend_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (source.used <= range.stop) return F_status_set_error(F_parameter);
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+ if (range.start > range.stop) return F_data_not_stop;
+
+ return private_f_string_prepend_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
+ }
+#endif // _di_f_string_dynamic_partial_prepend_nulless
+
+#ifndef _di_f_string_dynamic_prepend_
+ f_status_t f_string_dynamic_prepend(const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ return private_f_string_prepend(source.string, source.used, destination);
+ }
+#endif // _di_f_string_dynamic_prepend_
+
+#ifndef _di_f_string_dynamic_prepend_assure_
+ f_status_t f_string_dynamic_prepend_assure(const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ if (destination->used < source.used) {
+ return private_f_string_prepend(source.string, source.used, destination);
+ }
+
+ f_string_length_t i = 0;
+ f_string_length_t j = 0;
+
+ while (i < source.used && j < destination->used) {
+ if (!source.string[i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[j]) {
+ j++;
+ continue;
+ }
+
+ if (source.string[i] != destination->string[i]) {
+ return private_f_string_prepend(source.string, source.used, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_prepend_assure_
+
+#ifndef _di_f_string_dynamic_prepend_assure_nulless_
+ f_status_t f_string_dynamic_prepend_assure_nulless(const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ if (destination->used < source.used) {
+ return private_f_string_prepend_nulless(source.string, source.used, destination);
+ }
+
+ f_string_length_t i = 0;
+ f_string_length_t j = 0;
+
+ while (i < source.used && j < destination->used) {
+ if (!source.string[i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[j]) {
+ j++;
+ continue;
+ }
+
+ if (source.string[i] != destination->string[i]) {
+ return private_f_string_prepend_nulless(source.string, source.used, destination);
+ }
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_prepend_assure_nulless_
+
+#ifndef _di_f_string_dynamic_prepend_nulless_
+ f_status_t f_string_dynamic_prepend_nulless(const f_string_static_t source, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!source.used) return F_data_not_eos;
+
+ return private_f_string_prepend_nulless(source.string, source.used, destination);
+ }
+#endif // _di_f_string_dynamic_prepend_nulless_
+
+#ifndef _di_f_string_dynamic_terminate_
+ f_status_t f_string_dynamic_terminate(f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ if (destination->used > destination->size) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!destination->used && destination->size && !destination->string[destination->used - 1]) {
+ return F_none;
+ }
+
+ if (destination->used == f_string_length_t_size) {
+ return F_status_set_error(F_string_too_large);
+ }
+
+ const f_string_length_t total = destination->used + 1;
+
+ if (total > destination->size) {
+ const f_status_t status = private_f_string_dynamic_resize(total, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ destination->string[destination->used] = 0;
+ destination->used = total;
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_terminate_
+
+#ifndef _di_f_string_dynamic_terminate_after_
+ f_status_t f_string_dynamic_terminate_after(f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ if (destination->used > destination->size) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (destination->used) {
+ for (; destination->used; destination->used--) {
+ if (!destination->string[destination->used - 1]) continue;
+ break;
+ } // for
+ }
+
+ if (destination->used == f_string_length_t_size) {
+ return F_status_set_error(F_string_too_large);
+ }
+
+ const f_string_length_t total = destination->used + 1;
+
+ if (total > destination->size) {
+ const f_status_t status = private_f_string_dynamic_resize(total, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ destination->string[destination->used] = 0;
+ destination->used = total - 1;
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_terminate_after_
+
+#ifndef _di_f_string_mash_
+ f_status_t f_string_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ if (glue_length && destination->used) {
+ f_status_t status = private_f_string_append(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_append(source, length, destination);
+ }
+#endif // _di_f_string_mash_
+
+#ifndef _di_f_string_mash_nulless_
+ f_status_t f_string_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ if (glue_length && destination->used) {
+ f_status_t status = private_f_string_append_nulless(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_append_nulless(source, length, destination);
+ }
+#endif // _di_f_string_mash_nulless_
+
+#ifndef _di_f_string_mish_
+ f_status_t f_string_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ if (glue_length && destination->used) {
+ f_status_t status = private_f_string_prepend(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_prepend(source, length, destination);
+ }
+#endif // _di_f_string_mish_
+
+#ifndef _di_f_string_mish_nulless_
+ f_status_t f_string_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ if (glue_length && destination->used) {
+ f_status_t status = private_f_string_prepend_nulless(glue, glue_length, destination);
+ if (F_status_is_error(status)) return status;
+ }
+
+ return private_f_string_prepend_nulless(source, length, destination);
+ }
+#endif // _di_f_string_mish_nulless_
+
+#ifndef _di_f_string_prepend_
+ f_status_t f_string_prepend(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ return private_f_string_prepend(source, length, destination);
+ }
+#endif // _di_f_string_prepend_
+
+#ifndef _di_f_string_prepend_assure_
+ f_status_t f_string_prepend_assure(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+ if (destination->used < length) return private_f_string_prepend(source, length, destination);
+
+ f_string_length_t i = 0;
+ f_string_length_t j = 0;
+
+ while (i < length && j < destination->used) {
+ if (!source[i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[j]) {
+ j++;
+ continue;
+ }
+
+ if (source[i] != destination->string[i]) return private_f_string_prepend(source, length, destination);
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_prepend_assure_
+
+#ifndef _di_f_string_prepend_assure_nulless_
+ f_status_t f_string_prepend_assure_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+ if (destination->used < length) return private_f_string_prepend_nulless(source, length, destination);
+
+ f_string_length_t i = 0;
+ f_string_length_t j = 0;
+
+ while (i < length && j < destination->used) {
+ if (!source[i]) {
+ i++;
+ continue;
+ }
+
+ if (!destination->string[j]) {
+ j++;
+ continue;
+ }
+
+ if (source[i] != destination->string[i]) return private_f_string_prepend_nulless(source, length, destination);
+
+ i++;
+ j++;
+ } // while
+
+ return F_none;
+ }
+#endif // _di_f_string_prepend_assure_nulless_
+
+#ifndef _di_f_string_prepend_nulless_
+ f_status_t f_string_prepend_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
+ #ifndef _di_level_1_parameter_checking_
+ if (!destination) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
+
+ if (!length) return F_data_not_eos;
+
+ return private_f_string_prepend_nulless(source, length, destination);
+ }
+#endif // _di_f_string_prepend_nulless_
#ifdef __cplusplus
} // extern "C"
extern "C" {
#endif
+/**
+ * Append the source string onto the destination.
+ *
+ * @param source
+ * The source string to append.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_append_
+ extern f_status_t f_string_append(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_append_
+
+/**
+ * Append the source string onto the destination, but only if the string is not already at the end.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ *
+ * @param source
+ * The source string to append.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_append_assure_
+ extern f_status_t f_string_append_assure(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_append_assure_
+
+/**
+ * Append the source string onto the destination, but only if the string is not already at the end.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ * Skips over NULL characters from source when appending.
+ *
+ * @param source
+ * The source string to append.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_append_assure_nulless_
+ extern f_status_t f_string_append_assure_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_append_assure_nulless_
+
+/**
+ * Append the source string onto the destination.
+ *
+ * Skips over NULL characters from source when appending.
+ *
+ * @param source
+ * The source string to append.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_append_nulless_
+ extern f_status_t f_string_append_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_append_nulless_
+
+/**
+ * Append the source string onto the destination.
+ *
+ * @param source
+ * The source string to append.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_append_
+ extern f_status_t f_string_dynamic_append(const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_append_
+
+/**
+ * Append the source string onto the destination.
+ *
+ * @param source
+ * The source string to append.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_append_assure_
+ extern f_status_t f_string_dynamic_append_assure(const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_append_assure_
+
+/**
+ * Append the source string onto the destination.
+ *
+ * Skips over NULL characters from source when appending.
+ *
+ * @param source
+ * The source string to append.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_append_assure_nulless_
+ extern f_status_t f_string_dynamic_append_assure_nulless(const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_append_assure_nulless_
+
+/**
+ * Append the source string onto the destination.
+ *
+ * Skips over NULL characters from source when appending.
+ *
+ * @param source
+ * The source string to append.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_append_nulless_
+ extern f_status_t f_string_dynamic_append_nulless(const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_append_nulless_
+
+/**
+ * Append the source string onto the destination with the glue in between.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_mash_
+ extern f_status_t f_string_dynamic_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_mash_
+
+/**
+ * Append the source string onto the destination with the glue in between.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * Skips over NULL characters from glue and source when appending.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_mash_nulless_
+ extern f_status_t f_string_dynamic_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_mash_nulless_
+
+/**
+ * Prepend the source string onto the destination with the glue in between.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_mish_
+ extern f_status_t f_string_dynamic_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_mish_
+
+/**
+ * Prepend the source string onto the destination with the glue in between.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * Skips over NULL characters from glue and source when appending.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_mish_nulless_
+ extern f_status_t f_string_dynamic_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_mish_nulless_
+
+/**
+ * Append the source string onto the destination, but restricted to the given range.
+ *
+ * @param source
+ * The source string to append.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_append_
+ extern f_status_t f_string_dynamic_partial_append(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_append_
+
+/**
+ * Append the source string onto the destination, but only if the string is not already at the end and restricted to the given range
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ *
+ * @param source
+ * The source string to append.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_append_assure_
+ extern f_status_t f_string_dynamic_partial_append_assure(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_append_assure_
+
+/**
+ * Append the source string onto the destination, but only if the string is not already at the end and restricted to the given range
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ *
+ * Skips over NULL characters from source when appending.
+ *
+ * @param source
+ * The source string to append.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_append_assure_nulless_
+ extern f_status_t f_string_dynamic_partial_append_assure_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_append_assure_nulless_
+
+/**
+ * Append the source string onto the destination, but restricted to the given range.
+ *
+ * Skips over NULL characters from source when appending.
+ *
+ * @param source
+ * The source string to append.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source is appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_append_nulless_
+ extern f_status_t f_string_dynamic_partial_append_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_append_nulless_
+
+/**
+ * Append the source string onto the destination with the glue in between, but restricted to the given range.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_mash_
+ extern f_status_t f_string_dynamic_partial_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_mash_
+
+/**
+ * Append the source string onto the destination with the glue in between, but restricted to the given range.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * Skips over NULL characters from glue and source when appending.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_mash_nulless_
+ extern f_status_t f_string_dynamic_partial_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_mash_nulless_
+
+/**
+ * Prepend the source string onto the destination with the glue in between, but restricted to the given range.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_mish_
+ extern f_status_t f_string_dynamic_partial_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_mish_
+
+/**
+ * Prepend the source string onto the destination with the glue in between, but restricted to the given range.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * Skips over NULL characters from glue and source when appending.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_mish_nulless_
+ extern f_status_t f_string_dynamic_partial_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_mish_nulless_
+
+/**
+ * Prepend the source string onto the destination, but restricted to the given range.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_prepend_
+ extern f_status_t f_string_dynamic_partial_prepend(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_prepend_
+
+/**
+ * Prepend the source string onto the destination, but only if the string is not already at the end and restricted to the given range
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_prepend_assure_
+ extern f_status_t f_string_dynamic_partial_prepend_assure(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_prepend_assure_
+
+/**
+ * Prepend the source string onto the destination, but only if the string is not already at the end and restricted to the given range
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_prepend_assure_nulless_
+ extern f_status_t f_string_dynamic_partial_prepend_assure_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_prepend_assure_nulless_
+
+/**
+ * Prepend the source string onto the destination, but restricted to the given range.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param range
+ * A range within the source to restrict the copy from.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_partial_prepend_nulless_
+ extern f_status_t f_string_dynamic_partial_prepend_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_partial_prepend_nulless_
+
+/**
+ * Prepend the source string onto the destination.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_prepend_
+ extern f_status_t f_string_dynamic_prepend(const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_prepend_
+
+/**
+ * Prepend the source string onto the destination, but only if the string is not already at the beginning.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_prepend_assure_
+ extern f_status_t f_string_dynamic_prepend_assure(const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_prepend_assure_
+
+/**
+ * Prepend the source string onto the destination, but only if the string is not already at the beginning.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_prepend_assure_nulless_
+ extern f_status_t f_string_dynamic_prepend_assure_nulless(const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_prepend_assure_nulless_
+
+/**
+ * Prepend the source string onto the destination.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_data_not_stop if range.start > range.stop.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_prepend_nulless_
+ extern f_status_t f_string_dynamic_prepend_nulless(const f_string_static_t source, f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_prepend_nulless_
+
+/**
+ * Guarantee that an end of string (NULL) exists at the end of the string.
+ *
+ * This is intended to be used for anything requiring NULL terminated strings.
+ * This will reallocate more space if necessary.
+ *
+ * If destination size is 0, then it will be reallocated and have the NULL assigned at index 0.
+ *
+ * @param destination
+ * The new string, which will be allocated or reallocated as necessary.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if string is too large to fit into the buffer.
+ */
+#ifndef _di_f_string_dynamic_terminate_
+ extern f_status_t f_string_dynamic_terminate(f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_terminate_
+
+/**
+ * Guarantee that an end of string (NULL) exists at the end of the string.
+ *
+ * This ensures that the terminating NULL not only exists but is not counted in destination.used.
+ *
+ * This is intended to be used for anything requiring NULL terminated strings whose used length cannot be counted.
+ * This will reallocate more space if necessary.
+ *
+ * If destination size is 0, then it will be reallocated and have the NULL assigned at index 0.
+ *
+ * @param destination
+ * The new string, which will be allocated or reallocated as necessary.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if string is too large to fit into the buffer.
+ */
+#ifndef _di_f_string_dynamic_terminate_after_
+ extern f_status_t f_string_dynamic_terminate_after(f_string_dynamic_t *destination);
+#endif // _di_f_string_dynamic_terminate_after_
+
+/**
+ * Append the source string onto the destination with the glue in between.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_mash_
+ extern f_status_t f_string_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_mash_
+
+/**
+ * Append the source string onto the destination with the glue in between.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * Skips over NULL characters from glue and source when appending.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_mash_nulless_
+ extern f_status_t f_string_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_mash_nulless_
+
+/**
+ * Prepend the source string onto the destination with the glue in between.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_mish_
+ extern f_status_t f_string_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_mish_
+
+/**
+ * Prepend the source string onto the destination with the glue in between.
+ *
+ * If the destination string is empty, then no glue is appended.
+ *
+ * Skips over NULL characters from glue and source when appending.
+ *
+ * @param glue
+ * A string to append between the source and destination, such as a space: ' '.
+ * @param glue_length
+ * The number of bytes the glue takes up.
+ * @param source
+ * The source string to append.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source and glue are appended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_mish_nulless_
+ extern f_status_t f_string_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_mish_nulless_
+
+/**
+ * Prepend the source string onto the destination.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_prepend_
+ extern f_status_t f_string_prepend(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_prepend_
+
+/**
+ * Prepend the source string onto the destination, but only if the string is not already at the beginning.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_prepend_assure_
+ extern f_status_t f_string_prepend_assure(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_prepend_assure_
+
+/**
+ * Prepend the source string onto the destination, but only if the string is not already at the beginning.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ * Skips over NULL characters from source when prepending.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_prepend_assure_nulless_
+ extern f_status_t f_string_prepend_assure_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_prepend_assure_nulless_
+
+/**
+ * Prepend the source string onto the destination, but only if the string is not already at the beginning.
+ *
+ * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ *
+ * This ignores NULL characters when comparing both the source and the destination.
+ * Skips over NULL characters from source when prepending.
+ *
+ * @param source
+ * The source string to prepend.
+ * @param length
+ * The length of source to append.
+ * @param destination
+ * The destination string the source is prepended onto.
+ *
+ * @return
+ * F_none on success.
+ * F_data_not_eos if source length is 0.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_prepend_nulless_
+ extern f_status_t f_string_prepend_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_f_string_prepend_nulless_
+
#ifdef __cplusplus
} // extern "C"
#endif
--- /dev/null
+#include "string.h"
+#include "private-string.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _di_f_string_static_empty_s_
+ const f_string_static_t f_string_static_empty_s = f_macro_string_static_t_initialize("", 0);
+#endif // _di_f_string_static_empty_s_
+
+#ifndef _di_f_string_dynamic_adjust_
+ f_status_t f_string_dynamic_adjust(const f_string_length_t length, f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_dynamic_adjust(length, string);
+ }
+#endif // _di_f_string_dynamic_adjust_
+
+#ifndef _di_f_string_dynamic_decimate_
+ f_status_t f_string_dynamic_decimate(f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (string->size > 1) {
+ return private_f_string_dynamic_adjust(string->size - 1, string);
+ }
+
+ return private_f_string_dynamic_destroy(string);
+ }
+#endif // _di_f_string_dynamic_decimate_
+
+#ifndef _di_f_string_dynamic_decimate_by_
+ f_status_t f_string_dynamic_decimate_by(const f_string_length_t amount, f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (string->size - amount > 0) {
+ return private_f_string_dynamic_adjust(string->size - amount, string);
+ }
+
+ return private_f_string_dynamic_destroy(string);
+ }
+#endif // _di_f_string_dynamic_decimate_by_
+
+#ifndef _di_f_string_dynamic_decrease_
+ f_status_t f_string_dynamic_decrease(f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (string->size > 1) {
+ return private_f_string_dynamic_resize(string->size - 1, string);
+ }
+
+ return private_f_string_dynamic_delete(string);
+ }
+#endif // _di_f_string_dynamic_decrease_
+
+#ifndef _di_f_string_dynamic_decrease_by_
+ f_status_t f_string_dynamic_decrease_by(const f_string_length_t amount, f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (string->size - amount > 0) {
+ return private_f_string_dynamic_resize(string->size - amount, string);
+ }
+
+ return private_f_string_dynamic_delete(string);
+ }
+#endif // _di_f_string_dynamic_decrease_by_
+
+#ifndef _di_f_string_dynamic_delete_
+ f_status_t f_string_dynamic_delete(f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_dynamic_delete(string);
+ }
+#endif // _di_f_string_dynamic_delete_
+
+#ifndef _di_f_string_dynamic_destroy_
+ f_status_t f_string_dynamic_destroy(f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_dynamic_destroy(string);
+ }
+#endif // _di_f_string_dynamic_destroy_
+
+#ifndef _di_f_string_dynamic_increase_
+ f_status_t f_string_dynamic_increase(f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (string->used + 1 > string->size) {
+ f_array_length_t size = string->used + f_memory_default_allocation_step;
+
+ if (size > f_string_length_t_size) {
+ if (string->used + 1 > f_string_length_t_size) {
+ return F_status_set_error(F_string_too_large);
+ }
+
+ size = f_string_length_t_size;
+ }
+
+ return private_f_string_dynamic_resize(size, string);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamic_increase_
+
+#ifndef _di_f_string_dynamic_increase_by_
+ f_status_t f_string_dynamic_increase_by(const f_string_length_t amount, f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_dynamic_increase_by(amount, string);
+ }
+#endif // _di_f_string_dynamic_increase_by_
+
+#ifndef _di_f_string_dynamic_resize_
+ f_status_t f_string_dynamic_resize(const f_string_length_t length, f_string_dynamic_t *string) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!string) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_dynamic_resize(length, string);
+ }
+#endif // _di_f_string_dynamic_resize_
+
+#ifndef _di_f_string_dynamics_adjust_
+ f_status_t f_string_dynamics_adjust(const f_string_length_t length, f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_dynamics_adjust(length, strings);
+ }
+#endif // _di_f_string_dynamics_adjust_
+
+#ifndef _di_f_string_dynamics_decimate_
+ f_status_t f_string_dynamics_decimate(f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (strings->size > 1) {
+ return private_f_string_dynamics_adjust(strings->size - 1, strings);
+ }
+
+ return private_f_string_dynamics_destroy(strings);
+ }
+#endif // _di_f_string_dynamics_decimate_
+
+#ifndef _di_f_string_dynamics_decimate_by_
+ f_status_t f_string_dynamics_decimate_by(const f_array_length_t amount, f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (strings->size - amount > 0) {
+ return private_f_string_dynamics_adjust(strings->size - amount, strings);
+ }
+
+ return private_f_string_dynamics_destroy(strings);
+ }
+#endif // _di_f_string_dynamics_decimate_by_
+
+#ifndef _di_f_string_dynamics_decrease_
+ f_status_t f_string_dynamics_decrease(f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (strings->size > 1) {
+ return private_f_string_dynamics_resize(strings->size - 1, strings);
+ }
+
+ return private_f_string_dynamics_delete(strings);
+ }
+#endif // _di_f_string_dynamics_decrease_
+
+#ifndef _di_f_string_dynamics_decrease_by_
+ f_status_t f_string_dynamics_decrease_by(const f_array_length_t amount, f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (strings->size - amount > 0) {
+ return private_f_string_dynamics_resize(strings->size - amount, strings);
+ }
+
+ return private_f_string_dynamics_delete(strings);
+ }
+#endif // _di_f_string_dynamics_decrease_by_
+
+#ifndef _di_f_string_dynamics_delete_
+ f_status_t f_string_dynamics_delete(f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_dynamics_delete(strings);
+ }
+#endif // _di_f_string_dynamics_delete_
+
+#ifndef _di_f_string_dynamics_destroy_
+ f_status_t f_string_dynamics_destroy(f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_dynamics_destroy(strings);
+ }
+#endif // _di_f_string_dynamics_destroy_
+
+#ifndef _di_f_string_dynamics_increase_
+ f_status_t f_string_dynamics_increase(f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (strings->used + 1 > strings->size) {
+ f_array_length_t size = strings->used + f_memory_default_allocation_step;
+
+ if (size > f_array_length_t_size) {
+ if (strings->used + 1 > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ size = f_array_length_t_size;
+ }
+
+ return private_f_string_dynamics_resize(size, strings);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamics_increase_
+
+#ifndef _di_f_string_dynamics_increase_by_
+ f_status_t f_string_dynamics_increase_by(const f_array_length_t amount, f_string_dynamics_t *strings) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!strings) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (strings->used + amount > strings->size) {
+ if (strings->used + amount > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ return private_f_string_dynamics_resize(strings->used + amount, strings);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_dynamics_increase_by_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
status = F_none; \
if (length < dynamics.size) { \
for (register f_array_length_t _macro__i = dynamics.size - length; _macro__i < dynamics.size; ++_macro__i) { \
- f_macro_string_dynamic_t_destroy(status, dynamics.array[_macro__i], f_string_dynamic_t); \
+ f_macro_string_dynamic_t_destroy(status, dynamics.array[_macro__i]); \
if (status != F_none) break; \
} \
} \
} \
f_memory_destroy((void **) & dynamics.array, sizeof(f_string_dynamic_t), dynamics.size); \
dynamics.size = 0;
+
+ // @todo increase, decrease, decimate, increase_by, decrease_by, decimate_by
#endif // _di_f_string_dynamics_t_
#ifndef _di_f_string_static_empty_s_
const extern f_string_static_t f_string_static_empty_s;
#endif // _di_f_string_static_empty_s_
+/**
+ * Resize the dynamic string.
+ *
+ * @param length
+ * The new size to use.
+ * @param string
+ * The string to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamic_adjust_
+ extern f_status_t f_string_dynamic_adjust(const f_array_length_t length, f_string_dynamic_t *string);
+#endif // _di_f_string_dynamic_adjust_
+
+/**
+ * Resize the dynamic string to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param string
+ * The string to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamic_decrease_
+ extern f_status_t f_string_dynamic_decrease(f_string_dynamic_t *string);
+#endif // _di_f_string_dynamic_decrease_
+
+/**
+ * Resize the dynamic string to a smaller size.
+ *
+ * This will resize making the string smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decrease the size by.
+ * @param string
+ * The string to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamic_decrease_by_
+ extern f_status_t f_string_dynamic_decrease_by(const f_string_length_t amount, f_string_dynamic_t *string);
+#endif // _di_f_string_dynamic_decrease_by_
+
+/**
+ * Delete the dynamic string.
+ *
+ * @param string
+ * The string to delete.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamic_delete_
+ extern f_status_t f_string_dynamic_delete(f_string_dynamic_t *string);
+#endif // _di_f_string_dynamic_delete_
+
+/**
+ * Destroy the dynamic string.
+ *
+ * @param string
+ * The string to destroy.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamic_destroy_
+ extern f_status_t f_string_dynamic_destroy(f_string_dynamic_t *string);
+#endif // _di_f_string_dynamic_destroy_
+
+/**
+ * Resize the dynamic string to a larger size.
+ *
+ * This will resize making the string larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_string_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ * A positive number representing how much to increase the size by.
+ * @param string
+ * The string to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_increase_
+ extern f_status_t f_string_dynamic_increase(f_string_dynamic_t *string);
+#endif // _di_f_string_dynamic_increase_
+
+/**
+ * Resize the dynamic string to a larger size.
+ *
+ * This will resize making the string larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_string_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ * A positive number representing how much to increase the size by.
+ * @param string
+ * The string to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_string_too_large (with error bit) if the combined string is too large.
+ */
+#ifndef _di_f_string_dynamic_increase_by_
+ extern f_status_t f_string_dynamic_increase_by(const f_string_length_t amount, f_string_dynamic_t *string);
+#endif // _di_f_string_dynamic_increase_by_
+
+/**
+ * Resize the dynamic string.
+ *
+ * @param length
+ * The new size to use.
+ * @param string
+ * The string to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamic_resize_
+ extern f_status_t f_string_dynamic_resize(const f_array_length_t length, f_string_dynamic_t *string);
+#endif // _di_f_string_dynamic_resize_
+
+/**
+ * Resize the dynamic string array.
+ *
+ * @param length
+ * The new size to use.
+ * @param strings
+ * The string array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamics_adjust_
+ extern f_status_t f_string_dynamics_adjust(const f_array_length_t length, f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_adjust_
+
+/**
+ * Resize the dynamic string array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param strings
+ * The string array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamics_decimate_
+ extern f_status_t f_string_dynamics_decimate(f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_decimate_
+
+/**
+ * Resize the dynamic string array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decimate the size by.
+ * @param strings
+ * The string array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamics_decimate_by_
+ extern f_status_t f_string_dynamics_decimate_by(const f_array_length_t amount, f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_decimate_by_
+
+/**
+ * Resize the dynamic string array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param strings
+ * The string array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamics_decrease_
+ extern f_status_t f_string_dynamics_decrease(f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_decrease_
+
+/**
+ * Resize the dynamic string array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decrease the size by.
+ * @param strings
+ * The string array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamics_decrease_by_
+ extern f_status_t f_string_dynamics_decrease_by(const f_array_length_t amount, f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_decrease_by_
+
+/**
+ * Delete the array of dynamic strings.
+ *
+ * @param string
+ * The string to delete.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamics_delete_
+ extern f_status_t f_string_dynamics_delete(f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_delete_
+
+/**
+ * Destroy the array of dynamic strings.
+ *
+ * @param string
+ * The string to destroy.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamics_destroy_
+ extern f_status_t f_string_dynamics_destroy(f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_destroy_
+
+/**
+ * Increase the size of the dynamic string array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param strings
+ * The string array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_string_dynamics_increase_
+ extern f_status_t f_string_dynamics_increase(f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_increase_
+
+/**
+ * Resize the dynamic string array to a larger size.
+ *
+ * This will resize making the string larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ * A positive number representing how much to increase the size by.
+ * @param strings
+ * The string array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_string_dynamics_increase_by_
+ extern f_status_t f_string_dynamics_increase_by(const f_array_length_t amount, f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_increase_by_
+
+/**
+ * Resize the dynamic string array.
+ *
+ * @param length
+ * The new size to use.
+ * @param strings
+ * The string array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_dynamics_resize_
+ extern f_status_t f_string_dynamics_resize(const f_array_length_t length, f_string_dynamics_t *strings);
+#endif // _di_f_string_dynamics_resize_
+
#ifdef __cplusplus
} // extern "C"
#endif
--- /dev/null
+#include "string.h"
+#include "private-string.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _di_f_string_maps_adjust_
+ f_status_t f_string_maps_adjust(const f_string_length_t length, f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_maps_adjust(length, maps);
+ }
+#endif // _di_f_string_maps_adjust_
+
+#ifndef _di_f_string_maps_decimate_
+ f_status_t f_string_maps_decimate(f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (maps->size > 1) {
+ return private_f_string_maps_adjust(maps->size - 1, maps);
+ }
+
+ return private_f_string_maps_destroy(maps);
+ }
+#endif // _di_f_string_maps_decimate_
+
+#ifndef _di_f_string_maps_decimate_by_
+ f_status_t f_string_maps_decimate_by(const f_array_length_t amount, f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (maps->size - amount > 0) {
+ return private_f_string_maps_adjust(maps->size - amount, maps);
+ }
+
+ return private_f_string_maps_destroy(maps);
+ }
+#endif // _di_f_string_maps_decimate_by_
+
+#ifndef _di_f_string_maps_decrease_
+ f_status_t f_string_maps_decrease(f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (maps->size > 1) {
+ return private_f_string_maps_resize(maps->size - 1, maps);
+ }
+
+ return private_f_string_maps_delete(maps);
+ }
+#endif // _di_f_string_maps_decrease_
+
+#ifndef _di_f_string_maps_decrease_by_
+ f_status_t f_string_maps_decrease_by(const f_array_length_t amount, f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (maps->size - amount > 0) {
+ return private_f_string_maps_resize(maps->size - amount, maps);
+ }
+
+ return private_f_string_maps_delete(maps);
+ }
+#endif // _di_f_string_maps_decrease_by_
+
+#ifndef _di_f_string_maps_delete_
+ f_status_t f_string_maps_delete(f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_maps_delete(maps);
+ }
+#endif // _di_f_string_maps_delete_
+
+#ifndef _di_f_string_maps_destroy_
+ f_status_t f_string_maps_destroy(f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_maps_destroy(maps);
+ }
+#endif // _di_f_string_maps_destroy_
+
+#ifndef _di_f_string_maps_increase_
+ f_status_t f_string_maps_increase(f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (maps->used + 1 > maps->size) {
+ f_array_length_t size = maps->used + f_memory_default_allocation_step;
+
+ if (size > f_array_length_t_size) {
+ if (maps->used + 1 > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ size = f_array_length_t_size;
+ }
+
+ return private_f_string_maps_resize(size, maps);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_maps_increase_
+
+#ifndef _di_f_string_maps_increase_by_
+ f_status_t f_string_maps_increase_by(const f_array_length_t amount, f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (maps->used + amount > maps->size) {
+ if (maps->used + amount > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ return private_f_string_maps_resize(maps->used + amount, maps);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_maps_increase_by_
+
+#ifndef _di_f_string_maps_resize_
+ f_status_t f_string_maps_resize(const f_string_length_t length, f_string_maps_t *maps) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!maps) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_maps_resize(length, maps);
+ }
+#endif // _di_f_string_maps_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
status = F_none; \
if (length < maps.size) { \
for (register f_array_length_t _macro__i = maps.size - length; _macro__i < maps.size; ++_macro__i) { \
- f_macro_string_map_t_destroy(status, maps.array[_macro__i], f_string_map_t); \
+ f_macro_string_map_t_destroy(status, maps.array[_macro__i]); \
if (status != F_none) break; \
} \
} \
maps.size = 0;
#endif // _di_f_string_maps_t_
+// @todo increase, decrease, decimate, increase_by, decrease_by, decimate_by
+
/**
* A string map consisting of a name and multiple values.
*
status = F_none; \
if (length < maps.size) { \
for (register f_array_length_t _macro__i = maps.size - length; _macro__i < maps.size; ++_macro__i) { \
- f_macro_string_map_multi_t_destroy(status, maps.array[_macro__i], f_string_map_multi_t); \
+ f_macro_string_map_multi_t_destroy(status, maps.array[_macro__i]); \
if (status != F_none) break; \
} \
} \
maps.size = 0;
#endif // _di_f_string_map_multis_t_
+// @todo increase, decrease, decimate, increase_by, decrease_by, decimate_by
+
+/**
+ * Resize the string maps array.
+ *
+ * @param length
+ * The new size to use.
+ * @param maps
+ * The string maps array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_adjust_
+ extern f_status_t f_string_maps_adjust(const f_array_length_t length, f_string_maps_t *maps);
+#endif // _di_f_string_maps_adjust_
+
+/**
+ * Resize the string maps array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param maps
+ * The string maps array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_decimate_
+ extern f_status_t f_string_maps_decimate(f_string_maps_t *maps);
+#endif // _di_f_string_maps_decimate_
+
+/**
+ * Resize the string maps array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decimate the size by.
+ * @param maps
+ * The string maps array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_decimate_by_
+ extern f_status_t f_string_maps_decimate_by(const f_array_length_t amount, f_string_maps_t *maps);
+#endif // _di_f_string_maps_decimate_by_
+
+/**
+ * Resize the string maps array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param maps
+ * The string maps array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_decrease_
+ extern f_status_t f_string_maps_decrease(f_string_maps_t *maps);
+#endif // _di_f_string_maps_decrease_
+
+/**
+ * Resize the string maps array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decrease the size by.
+ * @param maps
+ * The string maps array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_decrease_by_
+ extern f_status_t f_string_maps_decrease_by(const f_array_length_t amount, f_string_maps_t *maps);
+#endif // _di_f_string_maps_decrease_by_
+
+/**
+ * Delete the array of string maps.
+ *
+ * @param maps
+ * The maps to delete.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_delete_
+ extern f_status_t f_string_maps_delete(f_string_maps_t *maps);
+#endif // _di_f_string_maps_delete_
+
+/**
+ * Delete the array of string maps.
+ *
+ * @param maps
+ * The maps to destroy.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_destroy_
+ extern f_status_t f_string_maps_destroy(f_string_maps_t *maps);
+#endif // _di_f_string_maps_destroy_
+
+/**
+ * Increase the size of the string maps array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param maps
+ * The string maps array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_increase_
+ extern f_status_t f_string_maps_increase(f_string_maps_t *maps);
+#endif // _di_f_string_maps_increase_
+
+/**
+ * Resize the string maps array to a larger size.
+ *
+ * This will resize making the string larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ * A positive number representing how much to increase the size by.
+ * @param maps
+ * The string maps array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_string_maps_increase_by_
+ extern f_status_t f_string_maps_increase_by(const f_array_length_t amount, f_string_maps_t *maps);
+#endif // _di_f_string_maps_increase_by_
+
+/**
+ * Resize the string maps array.
+ *
+ * @param length
+ * The new size to use.
+ * @param maps
+ * The string maps array to adjust.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_maps_adjust_
+ extern f_status_t f_string_maps_adjust(const f_array_length_t length, f_string_maps_t *maps);
+#endif // _di_f_string_maps_adjust_
+
#ifdef __cplusplus
} // extern "C"
#endif
--- /dev/null
+#include "string.h"
+#include "private-string.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _di_f_string_quantitys_adjust_
+ f_status_t f_string_quantitys_adjust(const f_string_length_t length, f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_quantitys_adjust(length, quantitys);
+ }
+#endif // _di_f_string_quantitys_adjust_
+
+#ifndef _di_f_string_quantitys_decimate_
+ f_status_t f_string_quantitys_decimate(f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (quantitys->size > 1) {
+ return private_f_string_quantitys_adjust(quantitys->size - 1, quantitys);
+ }
+
+ return private_f_string_quantitys_destroy(quantitys);
+ }
+#endif // _di_f_string_quantitys_decimate_
+
+#ifndef _di_f_string_quantitys_decimate_by_
+ f_status_t f_string_quantitys_decimate_by(const f_array_length_t amount, f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (quantitys->size - amount > 0) {
+ return private_f_string_quantitys_adjust(quantitys->size - amount, quantitys);
+ }
+
+ return private_f_string_quantitys_destroy(quantitys);
+ }
+#endif // _di_f_string_quantitys_decimate_by_
+
+#ifndef _di_f_string_quantitys_decrease_
+ f_status_t f_string_quantitys_decrease(f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (quantitys->size > 1) {
+ return private_f_string_quantitys_resize(quantitys->size - 1, quantitys);
+ }
+
+ return private_f_string_quantitys_delete(quantitys);
+ }
+#endif // _di_f_string_quantitys_decrease_
+
+#ifndef _di_f_string_quantitys_decrease_by_
+ f_status_t f_string_quantitys_decrease_by(const f_array_length_t amount, f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (quantitys->size - amount > 0) {
+ return private_f_string_quantitys_resize(quantitys->size - amount, quantitys);
+ }
+
+ return private_f_string_quantitys_delete(quantitys);
+ }
+#endif // _di_f_string_quantitys_decrease_by_
+
+#ifndef _di_f_string_quantitys_delete_
+ f_status_t f_string_quantitys_delete(f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_quantitys_delete(quantitys);
+ }
+#endif // _di_f_string_quantitys_delete_
+
+#ifndef _di_f_string_quantitys_destroy_
+ f_status_t f_string_quantitys_destroy(f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_quantitys_destroy(quantitys);
+ }
+#endif // _di_f_string_quantitys_destroy_
+
+#ifndef _di_f_string_quantitys_increase_
+ f_status_t f_string_quantitys_increase(f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (quantitys->used + 1 > quantitys->size) {
+ f_array_length_t size = quantitys->used + f_memory_default_allocation_step;
+
+ if (size > f_array_length_t_size) {
+ if (quantitys->used + 1 > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ size = f_array_length_t_size;
+ }
+
+ return private_f_string_quantitys_resize(size, quantitys);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_quantitys_increase_
+
+#ifndef _di_f_string_quantitys_increase_by_
+ f_status_t f_string_quantitys_increase_by(const f_array_length_t amount, f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (quantitys->used + amount > quantitys->size) {
+ if (quantitys->used + amount > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ return private_f_string_quantitys_resize(quantitys->used + amount, quantitys);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_quantitys_increase_by_
+
+#ifndef _di_f_string_quantitys_resize_
+ f_status_t f_string_quantitys_resize(const f_string_length_t length, f_string_quantitys_t *quantitys) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!quantitys) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_quantitys_resize(length, quantitys);
+ }
+#endif // _di_f_string_quantitys_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
#define f_macro_string_quantityss_t_delete_simple(quantityss) f_macro_memory_structures_delete_simple(quantityss, f_string_quantity_t, f_string_quantitys_t);
#define f_macro_string_quantityss_t_destroy_simple(quantityss) f_macro_memory_structures_destroy_simple(quantityss, f_string_quantity_t, f_string_quantitys_t);
+
+ #define f_macro_string_quantityss_t_increase(status, string_quantitys) f_macro_memory_structures_increase(status, string_quantitys, f_string_quantity_t, f_array_length_t);
+ #define f_macro_string_quantityss_t_decrease(status, string_quantitys) f_macro_memory_structures_decrease(status, string_quantitys, f_string_quantity_t, f_string_quantity_t);
+ #define f_macro_string_quantityss_t_decimate(status, string_quantitys) f_macro_memory_structures_decimate(status, string_quantitys, f_string_quantity_t, f_string_quantity_t);
+
+ #define f_macro_string_quantityss_t_increase_by(status, string_quantitys, amount) f_macro_memory_structures_increase_by(status, string_quantitys, f_string_quantity_t, f_array_length_t, amount);
+ #define f_macro_string_quantityss_t_decrease_by(status, string_quantitys, amount) f_macro_memory_structures_decrease_by(status, string_quantitys, f_string_quantity_t, f_string_quantitys_t, f_array_length_t, amount);
+ #define f_macro_string_quantityss_t_decimate_by(status, string_quantitys, amount) f_macro_memory_structures_decimate_by(status, string_quantitys, f_string_quantity_t, f_string_quantitys_t, f_array_length_t, amount);
#endif // _di_f_string_quantityss_t_
+/**
+ * Resize the string quantitys array.
+ *
+ * @param length
+ * The new size to use.
+ * @param quantitys
+ * The string quantitys array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_adjust_
+ extern f_status_t f_string_quantitys_adjust(const f_array_length_t length, f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_adjust_
+
+/**
+ * Resize the string quantitys array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param quantitys
+ * The string quantitys array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_decimate_
+ extern f_status_t f_string_quantitys_decimate(f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_decimate_
+
+/**
+ * Resize the string quantitys array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decimate the size by.
+ * @param quantitys
+ * The string quantitys array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_decimate_by_
+ extern f_status_t f_string_quantitys_decimate_by(const f_array_length_t amount, f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_decimate_by_
+
+/**
+ * Resize the string quantitys array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param quantitys
+ * The string quantitys array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_decrease_
+ extern f_status_t f_string_quantitys_decrease(f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_decrease_
+
+/**
+ * Resize the string quantitys array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decrease the size by.
+ * @param quantitys
+ * The string quantitys array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_decrease_by_
+ extern f_status_t f_string_quantitys_decrease_by(const f_array_length_t amount, f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_decrease_by_
+
+/**
+ * Delete the array of string quantitys.
+ *
+ * @param quantitys
+ * The quantitys to delete.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_delete_
+ extern f_status_t f_string_quantitys_delete(f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_delete_
+
+/**
+ * Delete the array of string quantitys.
+ *
+ * @param quantitys
+ * The quantitys to destroy.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_destroy_
+ extern f_status_t f_string_quantitys_destroy(f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_destroy_
+
+/**
+ * Increase the size of the string quantitys array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param quantitys
+ * The string quantitys array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_increase_
+ extern f_status_t f_string_quantitys_increase(f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_increase_
+
+/**
+ * Resize the string quantitys array to a larger size.
+ *
+ * This will resize making the string larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ * A positive number representing how much to increase the size by.
+ * @param quantitys
+ * The string quantitys array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_string_quantitys_increase_by_
+ extern f_status_t f_string_quantitys_increase_by(const f_array_length_t amount, f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_increase_by_
+
+/**
+ * Resize the string quantitys array.
+ *
+ * @param length
+ * The new size to use.
+ * @param quantitys
+ * The string quantitys array to adjust.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_quantitys_adjust_
+ extern f_status_t f_string_quantitys_adjust(const f_array_length_t length, f_string_quantitys_t *quantitys);
+#endif // _di_f_string_quantitys_adjust_
+
#ifdef __cplusplus
} // extern "C"
#endif
--- /dev/null
+#include "string.h"
+#include "private-string.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _di_f_string_ranges_adjust_
+ f_status_t f_string_ranges_adjust(const f_string_length_t length, f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_ranges_adjust(length, ranges);
+ }
+#endif // _di_f_string_ranges_adjust_
+
+#ifndef _di_f_string_ranges_decimate_
+ f_status_t f_string_ranges_decimate(f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (ranges->size > 1) {
+ return private_f_string_ranges_adjust(ranges->size - 1, ranges);
+ }
+
+ return private_f_string_ranges_destroy(ranges);
+ }
+#endif // _di_f_string_ranges_decimate_
+
+#ifndef _di_f_string_ranges_decimate_by_
+ f_status_t f_string_ranges_decimate_by(const f_array_length_t amount, f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (ranges->size - amount > 0) {
+ return private_f_string_ranges_adjust(ranges->size - amount, ranges);
+ }
+
+ return private_f_string_ranges_destroy(ranges);
+ }
+#endif // _di_f_string_ranges_decimate_by_
+
+#ifndef _di_f_string_ranges_decrease_
+ f_status_t f_string_ranges_decrease(f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (ranges->size > 1) {
+ return private_f_string_ranges_resize(ranges->size - 1, ranges);
+ }
+
+ return private_f_string_ranges_delete(ranges);
+ }
+#endif // _di_f_string_ranges_decrease_
+
+#ifndef _di_f_string_ranges_decrease_by_
+ f_status_t f_string_ranges_decrease_by(const f_array_length_t amount, f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (ranges->size - amount > 0) {
+ return private_f_string_ranges_resize(ranges->size - amount, ranges);
+ }
+
+ return private_f_string_ranges_delete(ranges);
+ }
+#endif // _di_f_string_ranges_decrease_by_
+
+#ifndef _di_f_string_ranges_delete_
+ f_status_t f_string_ranges_delete(f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_ranges_delete(ranges);
+ }
+#endif // _di_f_string_ranges_delete_
+
+#ifndef _di_f_string_ranges_destroy_
+ f_status_t f_string_ranges_destroy(f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_ranges_destroy(ranges);
+ }
+#endif // _di_f_string_ranges_destroy_
+
+#ifndef _di_f_string_ranges_increase_
+ f_status_t f_string_ranges_increase(f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (ranges->used + 1 > ranges->size) {
+ f_array_length_t size = ranges->used + f_memory_default_allocation_step;
+
+ if (size > f_array_length_t_size) {
+ if (ranges->used + 1 > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ size = f_array_length_t_size;
+ }
+
+ return private_f_string_ranges_resize(size, ranges);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_ranges_increase_
+
+#ifndef _di_f_string_ranges_increase_by_
+ f_status_t f_string_ranges_increase_by(const f_array_length_t amount, f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (ranges->used + amount > ranges->size) {
+ if (ranges->used + amount > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ return private_f_string_ranges_resize(ranges->used + amount, ranges);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_ranges_increase_by_
+
+#ifndef _di_f_string_ranges_resize_
+ f_status_t f_string_ranges_resize(const f_string_length_t length, f_string_ranges_t *ranges) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!ranges) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_ranges_resize(length, ranges);
+ }
+#endif // _di_f_string_ranges_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
#define f_macro_string_rangess_t_delete_simple(rangess) f_macro_memory_structures_delete_simple(rangess, f_string_range_t, f_string_ranges_t);
#define f_macro_string_rangess_t_destroy_simple(rangess) f_macro_memory_structures_destroy_simple(rangess, f_string_range_t, f_string_ranges_t);
+
+ #define f_macro_string_rangess_t_increase(status, string_ranges) f_macro_memory_structures_increase(status, string_ranges, f_string_range_t, f_array_length_t);
+ #define f_macro_string_rangess_t_decrease(status, string_ranges) f_macro_memory_structures_decrease(status, string_ranges, f_string_range_t, f_string_range_t);
+ #define f_macro_string_rangess_t_decimate(status, string_ranges) f_macro_memory_structures_decimate(status, string_ranges, f_string_range_t, f_string_range_t);
+
+ #define f_macro_string_rangess_t_increase_by(status, string_ranges, amount) f_macro_memory_structures_increase_by(status, string_ranges, f_string_range_t, f_array_length_t, amount);
+ #define f_macro_string_rangess_t_decrease_by(status, string_ranges, amount) f_macro_memory_structures_decrease_by(status, string_ranges, f_string_range_t, f_string_ranges_t, f_array_length_t, amount);
+ #define f_macro_string_rangess_t_decimate_by(status, string_ranges, amount) f_macro_memory_structures_decimate_by(status, string_ranges, f_string_range_t, f_string_ranges_t, f_array_length_t, amount);
#endif // _di_f_string_rangess_t_
+/**
+ * Resize the string ranges array.
+ *
+ * @param length
+ * The new size to use.
+ * @param ranges
+ * The string ranges array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_adjust_
+ extern f_status_t f_string_ranges_adjust(const f_array_length_t length, f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_adjust_
+
+/**
+ * Resize the string ranges array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param ranges
+ * The string ranges array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_decimate_
+ extern f_status_t f_string_ranges_decimate(f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_decimate_
+
+/**
+ * Resize the string ranges array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decimate the size by.
+ * @param ranges
+ * The string ranges array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_decimate_by_
+ extern f_status_t f_string_ranges_decimate_by(const f_array_length_t amount, f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_decimate_by_
+
+/**
+ * Resize the string ranges array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param ranges
+ * The string ranges array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_decrease_
+ extern f_status_t f_string_ranges_decrease(f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_decrease_
+
+/**
+ * Resize the string ranges array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decrease the size by.
+ * @param ranges
+ * The string ranges array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_decrease_by_
+ extern f_status_t f_string_ranges_decrease_by(const f_array_length_t amount, f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_decrease_by_
+
+/**
+ * Delete the array of string ranges.
+ *
+ * @param ranges
+ * The ranges to delete.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_delete_
+ extern f_status_t f_string_ranges_delete(f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_delete_
+
+/**
+ * Delete the array of string ranges.
+ *
+ * @param ranges
+ * The ranges to destroy.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_destroy_
+ extern f_status_t f_string_ranges_destroy(f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_destroy_
+
+/**
+ * Increase the size of the string ranges array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param ranges
+ * The string ranges array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_increase_
+ extern f_status_t f_string_ranges_increase(f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_increase_
+
+/**
+ * Resize the string ranges array to a larger size.
+ *
+ * This will resize making the string larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ * A positive number representing how much to increase the size by.
+ * @param ranges
+ * The string ranges array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_string_ranges_increase_by_
+ extern f_status_t f_string_ranges_increase_by(const f_array_length_t amount, f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_increase_by_
+
+/**
+ * Resize the string ranges array.
+ *
+ * @param length
+ * The new size to use.
+ * @param ranges
+ * The string ranges array to adjust.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_ranges_adjust_
+ extern f_status_t f_string_ranges_adjust(const f_array_length_t length, f_string_ranges_t *ranges);
+#endif // _di_f_string_ranges_adjust_
+
#ifdef __cplusplus
} // extern "C"
#endif
--- /dev/null
+#include "string.h"
+#include "private-string.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _di_f_string_triples_adjust_
+ f_status_t f_string_triples_adjust(const f_string_length_t length, f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_triples_adjust(length, triples);
+ }
+#endif // _di_f_string_triples_adjust_
+
+#ifndef _di_f_string_triples_decimate_
+ f_status_t f_string_triples_decimate(f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (triples->size > 1) {
+ return private_f_string_triples_adjust(triples->size - 1, triples);
+ }
+
+ return private_f_string_triples_destroy(triples);
+ }
+#endif // _di_f_string_triples_decimate_
+
+#ifndef _di_f_string_triples_decimate_by_
+ f_status_t f_string_triples_decimate_by(const f_array_length_t amount, f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (triples->size - amount > 0) {
+ return private_f_string_triples_adjust(triples->size - amount, triples);
+ }
+
+ return private_f_string_triples_destroy(triples);
+ }
+#endif // _di_f_string_triples_decimate_by_
+
+#ifndef _di_f_string_triples_decrease_
+ f_status_t f_string_triples_decrease(f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (triples->size > 1) {
+ return private_f_string_triples_resize(triples->size - 1, triples);
+ }
+
+ return private_f_string_triples_delete(triples);
+ }
+#endif // _di_f_string_triples_decrease_
+
+#ifndef _di_f_string_triples_decrease_by_
+ f_status_t f_string_triples_decrease_by(const f_array_length_t amount, f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (triples->size - amount > 0) {
+ return private_f_string_triples_resize(triples->size - amount, triples);
+ }
+
+ return private_f_string_triples_delete(triples);
+ }
+#endif // _di_f_string_triples_decrease_by_
+
+#ifndef _di_f_string_triples_delete_
+ f_status_t f_string_triples_delete(f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_triples_delete(triples);
+ }
+#endif // _di_f_string_triples_delete_
+
+#ifndef _di_f_string_triples_destroy_
+ f_status_t f_string_triples_destroy(f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_triples_destroy(triples);
+ }
+#endif // _di_f_string_triples_destroy_
+
+#ifndef _di_f_string_triples_increase_
+ f_status_t f_string_triples_increase(f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (triples->used + 1 > triples->size) {
+ f_array_length_t size = triples->used + f_memory_default_allocation_step;
+
+ if (size > f_array_length_t_size) {
+ if (triples->used + 1 > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ size = f_array_length_t_size;
+ }
+
+ return private_f_string_triples_resize(size, triples);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_triples_increase_
+
+#ifndef _di_f_string_triples_increase_by_
+ f_status_t f_string_triples_increase_by(const f_array_length_t amount, f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!amount) return F_status_set_error(F_parameter);
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ if (triples->used + amount > triples->size) {
+ if (triples->used + amount > f_array_length_t_size) {
+ return F_status_set_error(F_array_too_large);
+ }
+
+ return private_f_string_triples_resize(triples->used + amount, triples);
+ }
+
+ return F_none;
+ }
+#endif // _di_f_string_triples_increase_by_
+
+#ifndef _di_f_string_triples_resize_
+ f_status_t f_string_triples_resize(const f_string_length_t length, f_string_triples_t *triples) {
+ #ifndef _di_level_0_parameter_checking_
+ if (!triples) return F_status_set_error(F_parameter);
+ #endif // _di_level_0_parameter_checking_
+
+ return private_f_string_triples_resize(length, triples);
+ }
+#endif // _di_f_string_triples_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
status = F_none; \
if (length < triples.size) { \
for (register f_array_length_t _macro__i = triples.size - length; _macro__i < triples.size; ++_macro__i) { \
- f_macro_string_triple_t_destroy(status, triples.array[_macro__i], f_string_triple_t); \
+ f_macro_string_triple_t_destroy(status, triples.array[_macro__i]); \
if (status != F_none) break; \
} \
} \
triples.size = 0;
#endif // _di_f_string_triples_t_
+// @todo increase, decrease, decimate, increase_by, decrease_by, decimate_by
+
+/**
+ * Resize the string triples array.
+ *
+ * @param length
+ * The new size to use.
+ * @param triples
+ * The string triples array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_adjust_
+ extern f_status_t f_string_triples_adjust(const f_array_length_t length, f_string_triples_t *triples);
+#endif // _di_f_string_triples_adjust_
+
+/**
+ * Resize the string triples array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param triples
+ * The string triples array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_decimate_
+ extern f_status_t f_string_triples_decimate(f_string_triples_t *triples);
+#endif // _di_f_string_triples_decimate_
+
+/**
+ * Resize the string triples array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decimate the size by.
+ * @param triples
+ * The string triples array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_decimate_by_
+ extern f_status_t f_string_triples_decimate_by(const f_array_length_t amount, f_string_triples_t *triples);
+#endif // _di_f_string_triples_decimate_by_
+
+/**
+ * Resize the string triples array to a smaller size, by 1.
+ *
+ * This will shrink the size by size - 1.
+ * This will not shrink the size to less than 0.
+ *
+ * @param triples
+ * The string triples array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_decrease_
+ extern f_status_t f_string_triples_decrease(f_string_triples_t *triples);
+#endif // _di_f_string_triples_decrease_
+
+/**
+ * Resize the string triples array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ * A positive number representing how much to decrease the size by.
+ * @param triples
+ * The string triples array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_decrease_by_
+ extern f_status_t f_string_triples_decrease_by(const f_array_length_t amount, f_string_triples_t *triples);
+#endif // _di_f_string_triples_decrease_by_
+
+/**
+ * Delete the array of string triples.
+ *
+ * @param triples
+ * The triples to delete.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_delete_
+ extern f_status_t f_string_triples_delete(f_string_triples_t *triples);
+#endif // _di_f_string_triples_delete_
+
+/**
+ * Delete the array of string triples.
+ *
+ * @param triples
+ * The triples to destroy.
+ *
+ * @return
+ * F_none on success.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_destroy_
+ extern f_status_t f_string_triples_destroy(f_string_triples_t *triples);
+#endif // _di_f_string_triples_destroy_
+
+/**
+ * Increase the size of the string triples array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param triples
+ * The string triples array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_increase_
+ extern f_status_t f_string_triples_increase(f_string_triples_t *triples);
+#endif // _di_f_string_triples_increase_
+
+/**
+ * Resize the string triples array to a larger size.
+ *
+ * This will resize making the string larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ * A positive number representing how much to increase the size by.
+ * @param triples
+ * The string triples array to resize.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ * F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_string_triples_increase_by_
+ extern f_status_t f_string_triples_increase_by(const f_array_length_t amount, f_string_triples_t *triples);
+#endif // _di_f_string_triples_increase_by_
+
+/**
+ * Resize the string triples array.
+ *
+ * @param length
+ * The new size to use.
+ * @param triples
+ * The string triples array to adjust.
+ *
+ * @return
+ * F_none on success.
+ * F_memory_not (with error bit) on out of memory.
+ * F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_string_triples_adjust_
+ extern f_status_t f_string_triples_adjust(const f_array_length_t length, f_string_triples_t *triples);
+#endif // _di_f_string_triples_adjust_
+
#ifdef __cplusplus
} // extern "C"
#endif
build_language c
build_libraries -lc
build_libraries-individual -lf_memory
-build_sources_library string.c string-common.c
+build_sources_library string.c string-common.c private-string.c string_dynamic.c string_map.c string_quantity.c string_range.c string_triple.c
build_sources_program
-build_sources_headers string.h string-common.h string_dynamic.h string_map.h string_quantity.h string_range.h string_triple.h
+build_sources_headers string.h string-common.h private-string.h string_dynamic.h string_map.h string_quantity.h string_range.h string_triple.h
build_sources_script
build_sources_setting
build_script yes
extern "C" {
#endif
-#if !defined(_di_fl_string_append_) || !defined(_di_fl_string_dynamic_append_) || !defined(_di_fl_string_dynamic_mash_) || !defined(_di_fl_string_mash_)
- f_status_t private_fl_string_append(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- f_status_t status = F_none;
-
- if (destination->used + length > destination->size) {
- status = private_fl_string_dynamic_increase_by(length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- memcpy(destination->string + destination->used, source, length);
- destination->used = destination->used + length;
-
- return F_none;
- }
-#endif // !defined(_di_fl_string_append_) || !defined(_di_fl_string_dynamic_append_) || !defined(_di_fl_string_dynamic_mash_) || !defined(_di_fl_string_mash_)
-
-#if !defined(_di_fl_string_append_nulless_) || !defined(_di_fl_string_dynamic_append_nulless_) || !defined(_di_fl_string_dynamic_mash_nulless_) || !defined(_di_fl_string_mash_nulless_)
- f_status_t private_fl_string_append_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
-
- if (destination->used + length > f_string_length_t_size) {
- return F_status_set_error(F_string_too_large);
- }
-
- f_status_t status = F_none;
-
- f_string_length_t i = 0;
- f_string_length_t first = 0;
- f_string_length_t size = 0;
-
- for (; i < length; i++) {
-
- if (source[i]) continue;
-
- if (i && i > first) {
- size = i - first;
-
- if (destination->used + size > destination->size) {
- status = private_fl_string_dynamic_increase_by(size, destination);
- if (F_status_is_error(status)) return status;
- }
-
- memcpy(destination->string + destination->used, source + first, size);
- destination->used = destination->used + size;
- }
-
- while (i + 1 < length && !source[i + 1]) {
- i++;
- } // while
-
- first = i + 1;
- } // for
-
- if (i > first) {
- size = i - first;
-
- if (destination->used + size > destination->size) {
- status = private_fl_string_dynamic_increase_by(size, destination);
- if (F_status_is_error(status)) return status;
- }
-
- memcpy(destination->string + destination->used, source + first, size);
- destination->used = destination->used + size;
- }
-
- return F_none;
- }
-#endif // !defined(_di_fl_string_append_nulless_) || !defined(_di_fl_string_dynamic_append_nulless_) || !defined(_di_fl_string_dynamic_mash_nulless_) || !defined(_di_fl_string_mash_nulless_)
-
#if !defined(_di_fl_string_compare_) || !defined(_di_fl_string_dynamic_compare_) || !defined(_di_fl_string_dynamic_partial_compare_)
f_status_t private_fl_string_compare(const f_string_t string1, const f_string_t string2, const f_string_length_t offset1, const f_string_length_t offset2, const f_string_length_t stop1, const f_string_length_t stop2) {
f_string_length_t i1 = offset1;
}
#endif // !defined(_di_fl_string_compare_trim_) || !defined(_di_fl_string_dynamic_compare_trim_) || !defined(_di_fl_string_dynamic_partial_compare_trim_)
-#if !defined(_di_fl_string_dynamic_decrease_) || !defined(_di_fl_string_dynamic_decrease_by_) || !defined(_di_fl_string_dynamic_delete_)
- void private_fl_string_dynamic_delete(f_string_dynamic_t *string) {
- f_macro_string_dynamic_t_delete_simple((*string));
- }
-#endif // !defined(_di_fl_string_dynamic_decrease_) || !defined(_di_fl_string_dynamic_decrease_by_) || !defined(_di_fl_string_dynamic_delete_)
-
-#if !defined(_di_fl_string_dynamic_increase_by_) || !defined(_di_fl_string_append_) || !defined(_di_fl_string_dynamic_append_) || !defined(_di_fl_string_append_mash_) || !defined(_di_fl_string_dynamic_mash_) || !defined(_di_fl_string_append_nulless_) || !defined(_di_fl_string_dynamic_append_nulless_) || !defined(_di_fl_string_mash_nulless_) || !defined(_di_fl_string_dynamic_mash_nulless_) || !defined(_di_fl_string_prepend_) || !defined(_di_fl_string_dynamic_prepend_) || !defined(_di_fl_string_prepend_nulless_) || !defined(_di_fl_string_dynamic_prepend_nulless_)
- f_status_t private_fl_string_dynamic_increase_by(const f_string_length_t amount, f_string_dynamic_t *string) {
-
- if (string->used + amount > string->size) {
- if (string->used + amount > f_string_length_t_size) {
- return F_status_set_error(F_string_too_large);
- }
-
- return private_fl_string_dynamic_resize(string->used + amount, string);
- }
-
- return F_none;
- }
-#endif // !defined(_di_fl_string_dynamic_increase_by_) || !defined(_di_fl_string_append_) || !defined(_di_fl_string_dynamic_append_) || !defined(_di_fl_string_append_mash_) || !defined(_di_fl_string_dynamic_mash_) || !defined(_di_fl_string_append_nulless_) || !defined(_di_fl_string_dynamic_append_nulless_) || !defined(_di_fl_string_mash_nulless_) || !defined(_di_fl_string_dynamic_mash_nulless_) || !defined(_di_fl_string_prepend_) || !defined(_di_fl_string_dynamic_prepend_) || !defined(_di_fl_string_prepend_nulless_) || !defined(_di_fl_string_dynamic_prepend_nulless_)
-
-#if !defined(_di_fl_string_dynamic_decrease_) || !defined(_di_fl_string_dynamic_decrease_by_) || !defined(_di_fl_string_dynamic_increase_) || !defined(_di_fl_string_dynamic_increase_by_) || !defined(_di_fl_string_dynamic_terminate_) || !defined(_di_fl_string_dynamic_terminate_after_)
- f_status_t private_fl_string_dynamic_resize(const f_string_length_t length, f_string_dynamic_t *string) {
- f_status_t status = F_none;
-
- f_macro_string_dynamic_t_resize(status, (*string), length);
-
- return status;
- }
-#endif // !defined(_di_fl_string_dynamic_decrease_) || !defined(_di_fl_string_dynamic_decrease_by_) || !defined(_di_fl_string_dynamic_increase_) || !defined(_di_fl_string_dynamic_increase_by_) || !defined(_di_fl_string_dynamic_terminate_) || !defined(_di_fl_string_dynamic_terminate_after_)
-
-#if !defined(_di_fl_string_dynamics_decrease_) || !defined(_di_fl_string_dynamics_decrease_by_) || !defined(_di_fl_string_dynamics_delete_)
- void private_fl_string_dynamics_delete(f_string_dynamics_t *string) {
- f_macro_string_dynamics_t_delete_simple((*string));
- }
-#endif // !defined(_di_fl_string_dynamics_decrease_) || !defined(_di_fl_string_dynamics_decrease_by_) || !defined(_di_fl_string_dynamics_delete_)
-
-#if !defined(_di_fl_string_dynamics_decrease_) || !defined(_di_fl_string_dynamics_decrease_by_) || !defined(_di_fl_string_dynamics_increase_) || !defined(_di_fl_string_dynamics_increase_by_) || !defined(_di_fl_string_dynamics_terminate_) || !defined(_di_fl_string_dynamics_terminate_after_)
- f_status_t private_fl_string_dynamics_resize(const f_string_length_t length, f_string_dynamics_t *strings) {
- f_status_t status = F_none;
-
- f_macro_string_dynamics_t_resize(status, (*strings), length);
-
- return status;
- }
-#endif // !defined(_di_fl_string_dynamics_decrease_) || !defined(_di_fl_string_dynamics_decrease_by_) || !defined(_di_fl_string_dynamics_increase_) || !defined(_di_fl_string_dynamics_increase_by_) || !defined(_di_fl_string_dynamics_terminate_) || !defined(_di_fl_string_dynamics_terminate_after_)
-
-#if !defined(fl_string_maps_decrease) || !defined(fl_string_maps_decrease_by) || !defined(_di_fl_string_maps_delete_)
- void private_fl_string_maps_delete(f_string_maps_t *maps) {
- f_macro_string_maps_t_delete_simple((*maps));
- }
-#endif // !defined(fl_string_maps_decrease) || !defined(fl_string_maps_decrease_by) || !defined(_di_fl_string_maps_delete_)
-
-#if !defined(_di_fl_string_maps_decrease_) || !defined(_di_fl_string_maps_decrease_by_) || !defined(_di_fl_string_maps_increase_) || !defined(_di_fl_string_maps_increase_by_) || !defined(_di_fl_string_maps_terminate_) || !defined(_di_fl_string_maps_terminate_after_)
- f_status_t private_fl_string_maps_resize(const f_string_length_t length, f_string_maps_t *maps) {
- f_status_t status = F_none;
-
- f_macro_string_maps_t_resize(status, (*maps), length);
-
- return status;
- }
-#endif // !defined(_di_fl_string_maps_decrease_) || !defined(_di_fl_string_maps_decrease_by_) || !defined(_di_fl_string_maps_increase_) || !defined(_di_fl_string_maps_increase_by_) || !defined(_di_fl_string_maps_terminate_) || !defined(_di_fl_string_maps_terminate_after_)
-
-#if !defined(_di_fl_string_dynamic_mish_) || !defined(_di_fl_string_dynamic_partial_mish_) || !defined(_di_fl_string_dynamic_partial_prepend_assure_) || !defined(_di_fl_string_dynamic_partial_prepend_) || !defined(_di_fl_string_dynamic_prepend_assure_) || !defined(_di_fl_string_dynamic_prepend_) || !defined(_di_fl_string_mish_) || !defined(_di_fl_string_prepend_assure_) || !defined(_di_fl_string_prepend_)
- f_status_t private_fl_string_prepend(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
-
- if (destination->used + length > f_string_length_t_size) {
- return F_status_set_error(F_string_too_large);
- }
-
- if (destination->used + length > destination->size) {
- const f_status_t status = private_fl_string_dynamic_increase_by(length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- if (destination->used) {
- memmove(destination->string + length, destination->string, destination->used);
- memcpy(destination->string, source, length);
- }
- else {
- memcpy(destination->string, source, length);
- }
-
- destination->used = destination->used + length;
- return F_none;
- }
-#endif // !defined(_di_fl_string_dynamic_mish_) || !defined(_di_fl_string_dynamic_partial_mish_) || !defined(_di_fl_string_dynamic_partial_prepend_assure_) || !defined(_di_fl_string_dynamic_partial_prepend_) || !defined(_di_fl_string_dynamic_prepend_assure_) || !defined(_di_fl_string_dynamic_prepend_) || !defined(_di_fl_string_mish_) || !defined(_di_fl_string_prepend_assure_) || !defined(_di_fl_string_prepend_)
-
-#if !defined(_di_fl_string_dynamic_mish_nulless_) || !defined(_di_fl_string_dynamic_partial_mish_nulless_) || !defined(_di_fl_string_dynamic_partial_prepend_assure_nulless_) || !defined(_di_fl_string_dynamic_partial_prepend_nulless_) || !defined(_di_fl_string_dynamic_prepend_assure_nulless_) || !defined(_di_fl_string_dynamic_prepend_nulless_) || !defined(_di_fl_string_mish_nulless_) || !defined(_di_fl_string_prepend_assure_nulless_) || !defined(_di_fl_string_prepend_nulless_)
- f_status_t private_fl_string_prepend_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
-
- if (destination->used + length > f_string_length_t_size) {
- return F_status_set_error(F_string_too_large);
- }
-
- f_status_t status = F_none;
-
- f_string_length_t first = 0;
- f_string_length_t offset = 0;
-
- f_string_length_t size = 0;
-
- for (f_string_length_t i = 0; i <= length; i++) {
-
- if (i == length) {
- if (i > first) {
- size = i - first;
-
- if (destination->used + size > destination->size) {
- status = private_fl_string_dynamic_increase_by(size, destination);
- if (F_status_is_error(status)) return status;
- }
-
- memmove(destination->string + offset + size, destination->string + offset, destination->used - offset);
- memcpy(destination->string + offset, source + first, size);
-
- destination->used = destination->used + size;
- offset += size;
- }
-
- break;
- }
-
- if (!source[i]) {
- if (i > 0) {
- if (i > first) {
- size = i - first;
-
- if (destination->used + size > destination->size) {
- status = private_fl_string_dynamic_increase_by(size, destination);
- if (F_status_is_error(status)) return status;
- }
-
- memmove(destination->string + offset + size, destination->string + offset, destination->used - offset);
- memcpy(destination->string + offset, source + first, size);
-
- destination->used = destination->used + size;
- offset += size;
- }
- }
-
- while (i + 1 < length && !source[i + 1]) {
- i++;
- } // while
-
- first = i + 1;
- continue;
- }
- } // for
-
- return F_none;
- }
-#endif // !defined(_di_fl_string_dynamic_mish_nulless_) || !defined(_di_fl_string_dynamic_partial_mish_nulless_) || !defined(_di_fl_string_dynamic_partial_prepend_assure_nulless_) || !defined(_di_fl_string_dynamic_partial_prepend_nulless_) || !defined(_di_fl_string_dynamic_prepend_assure_nulless_) || !defined(_di_fl_string_dynamic_prepend_nulless_) || !defined(_di_fl_string_mish_nulless_) || !defined(_di_fl_string_prepend_assure_nulless_) || !defined(_di_fl_string_prepend_nulless_)
-
#if !defined(_di_fl_string_rip_) || !defined(_di_fl_string_dynamic_rip_) || !defined(_di_fl_string_rip_nulless_) || !defined(_di_fl_string_dynamic_rip_nulless_)
f_status_t private_fl_string_rip_find_range(const f_string_t source, f_string_length_t *start, f_string_length_t *stop) {
const f_string_length_t stop_original = *stop;
#endif
/**
- * Private implementation of fl_string_append().
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param source
- * The source string to append.
- * @param length
- * Length of source to append.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- *
- * @return
- * F_none on success.
- *
- * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- *
- * @see memcpy()
- *
- * @see f_macro_string_dynamic_t_resize()
- * @see fl_string_append()
- * @see fl_string_dynamic_append()
- * @see fl_string_dynamic_mash()
- * @see fl_string_mash()
- */
-#if !defined(_di_fl_string_append_) || !defined(_di_fl_string_dynamic_append_) || !defined(_di_fl_string_dynamic_mash_) || !defined(_di_fl_string_mash_)
- extern f_status_t private_fl_string_append(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_append_) || !defined(_di_fl_string_dynamic_append_) || !defined(_di_fl_string_dynamic_mash_) || !defined(_di_fl_string_mash_)
-
-/**
- * Private implementation of fl_string_append_nulless().
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param source
- * The source string to append.
- * @param length
- * Length of source to append.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- *
- * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- *
- * @see memcpy()
- *
- * @see f_macro_string_dynamic_t_resize()
- * @see fl_string_append_nulless()
- * @see fl_string_dynamic_append_nulless()
- * @see fl_string_dynamic_mash_nulless()
- * @see fl_string_mash_nulless()
- */
-#if !defined(_di_fl_string_append_nulless_) || !defined(_di_fl_string_dynamic_append_nulless_) || !defined(_di_fl_string_dynamic_mash_nulless_) || !defined(_di_fl_string_mash_nulless_)
- extern f_status_t private_fl_string_append_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_append_nulless_) || !defined(_di_fl_string_dynamic_append_nulless_) || !defined(_di_fl_string_dynamic_mash_nulless_) || !defined(_di_fl_string_mash_nulless_)
-
-/**
* Private implementation of fl_string_compare().
*
* Intended to be shared to each of the different implementation variations.
#endif // !defined(_di_fl_string_compare_trim_) || !defined(_di_fl_string_dynamic_compare_trim_) || !defined(_di_fl_string_dynamic_partial_compare_trim_)
/**
- * Private implementation of fl_string_dynamic_delete().
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param string
- * The string to delete.
- *
- * @see fl_string_dynamic_decrease()
- * @see fl_string_dynamic_decrease_by()
- * @see fl_string_dynamic_delete()
- */
-#if !defined(_di_fl_string_dynamic_decrease_) || !defined(_di_fl_string_dynamic_decrease_by_) || !defined(_di_fl_string_dynamic_delete_)
- extern void private_fl_string_dynamic_delete(f_string_dynamic_t *string) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_dynamic_decrease_) || !defined(_di_fl_string_dynamic_decrease_by_) || !defined(_di_fl_string_dynamic_delete_)
-
-/**
- * Private implementation of fl_string_dynamic_increase_by().
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param amount
- * A positive number representing how much to increase the size by.
- * @param string
- * The string to resize.
- *
- * @return
- * F_none on success.
- * F_string_too_large (with error bit) if the combined string is too large.
- *
- * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- *
- * @see memcpy()
- *
- * @see fl_string_append()
- * @see fl_string_append_mash()
- * @see fl_string_append_nulless()
- * @see fl_string_dynamic_append()
- * @see fl_string_dynamic_append_nulless()
- * @see fl_string_dynamic_increase_by()
- * @see fl_string_dynamic_mash()
- * @see fl_string_dynamic_mash_nulless()
- * @see fl_string_dynamic_prepend()
- * @see fl_string_dynamic_prepend_nulless()
- * @see fl_string_mash_nulless()
- * @see fl_string_prepend()
- * @see fl_string_prepend_nulless()
- */
-#if !defined(_di_fl_string_dynamic_increase_by_) || !defined(_di_fl_string_append_) || !defined(_di_fl_string_dynamic_append_) || !defined(_di_fl_string_append_mash_) || !defined(_di_fl_string_dynamic_mash_) || !defined(_di_fl_string_append_nulless_) || !defined(_di_fl_string_dynamic_append_nulless_) || !defined(_di_fl_string_mash_nulless_) || !defined(_di_fl_string_dynamic_mash_nulless_) || !defined(_di_fl_string_prepend_) || !defined(_di_fl_string_dynamic_prepend_) || !defined(_di_fl_string_prepend_nulless_) || !defined(_di_fl_string_dynamic_prepend_nulless_)
- extern f_status_t private_fl_string_dynamic_increase_by(const f_string_length_t amount, f_string_dynamic_t *string) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_dynamic_increase_by_) || !defined(_di_fl_string_append_) || !defined(_di_fl_string_dynamic_append_) || !defined(_di_fl_string_append_mash_) || !defined(_di_fl_string_dynamic_mash_) || !defined(_di_fl_string_append_nulless_) || !defined(_di_fl_string_dynamic_append_nulless_) || !defined(_di_fl_string_mash_nulless_) || !defined(_di_fl_string_dynamic_mash_nulless_) || !defined(_di_fl_string_prepend_) || !defined(_di_fl_string_dynamic_prepend_) || !defined(_di_fl_string_prepend_nulless_) || !defined(_di_fl_string_dynamic_prepend_nulless_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- * The new size to use.
- * @param string
- * The string to resize.
- *
- * @return
- * F_none on success.
- *
- * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- *
- * @see f_macro_string_dynamic_t_resize()
- * @see fl_string_dynamic_decrease()
- * @see fl_string_dynamic_decrease_by()
- * @see fl_string_dynamic_increase()
- * @see fl_string_dynamic_increase_by()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamic_terminate_after()
- */
-#if !defined(_di_fl_string_dynamic_decrease_) || !defined(_di_fl_string_dynamic_decrease_by_) || !defined(_di_fl_string_dynamic_increase_) || !defined(_di_fl_string_dynamic_increase_by_) || !defined(_di_fl_string_dynamic_terminate_) || !defined(_di_fl_string_dynamic_terminate_after_)
- extern f_status_t private_fl_string_dynamic_resize(const f_string_length_t length, f_string_dynamic_t *string) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_dynamic_decrease_) || !defined(_di_fl_string_dynamic_decrease_by_) || !defined(_di_fl_string_dynamic_increase_) || !defined(_di_fl_string_dynamic_increase_by_) || !defined(_di_fl_string_dynamic_terminate_) || !defined(_di_fl_string_dynamic_terminate_after_)
-
-/**
- * Private implementation of fl_string_dynamics_delete().
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param strings
- * The strings to delete.
- *
- * @see fl_string_dynamics_decrease()
- * @see fl_string_dynamics_decrease_by()
- * @see fl_string_dynamics_delete()
- */
-#if !defined(_di_fl_string_dynamics_decrease_) || !defined(_di_fl_string_dynamics_decrease_by_) || !defined(_di_fl_string_dynamics_delete_)
- extern void private_fl_string_dynamics_delete(f_string_dynamics_t *strings) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_dynamics_decrease_) || !defined(_di_fl_string_dynamics_decrease_by_) || !defined(_di_fl_string_dynamics_delete_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- * The new size to use.
- * @param strings
- * The strings to resize.
- *
- * @return
- * F_none on success.
- *
- * Errors (with error bit) from: f_macro_string_dynamics_t_resize().
- *
- * @see f_macro_string_dynamics_t_resize()
- * @see fl_string_dynamics_decrease()
- * @see fl_string_dynamics_decrease_by()
- * @see fl_string_dynamics_increase()
- * @see fl_string_dynamics_increase_by()
- * @see fl_string_dynamics_terminate()
- * @see fl_string_dynamics_terminate_after()
- */
-#if !defined(_di_fl_string_dynamics_decrease_) || !defined(_di_fl_string_dynamics_decrease_by_) || !defined(_di_fl_string_dynamics_increase_) || !defined(_di_fl_string_dynamics_increase_by_) || !defined(_di_fl_string_dynamics_terminate_) || !defined(_di_fl_string_dynamics_terminate_after_)
- extern f_status_t private_fl_string_dynamics_resize(const f_string_length_t length, f_string_dynamics_t *strings) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_dynamics_decrease_) || !defined(_di_fl_string_dynamics_decrease_by_) || !defined(_di_fl_string_dynamics_increase_) || !defined(_di_fl_string_dynamics_increase_by_) || !defined(_di_fl_string_dynamics_terminate_) || !defined(_di_fl_string_dynamics_terminate_after_)
-
-/**
- * Private implementation of fl_string_maps_delete().
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param maps
- * The maps to delete.
- *
- * @see fl_string_maps_decrease()
- * @see fl_string_maps_decrease_by()
- * @see fl_string_maps_delete()
- */
-#if !defined(fl_string_maps_decrease) || !defined(fl_string_maps_decrease_by) || !defined(_di_fl_string_maps_delete_)
- extern void private_fl_string_maps_delete(f_string_maps_t *maps) f_gcc_attribute_visibility_internal;
-#endif // !defined(fl_string_maps_decrease) || !defined(fl_string_maps_decrease_by) || !defined(_di_fl_string_maps_delete_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- * The new size to use.
- * @param maps
- * The maps to resize.
- *
- * @return
- * F_none on success.
- *
- * Errors (with error bit) from: f_macro_string_maps_t_resize().
- *
- * @see f_macro_string_dynamic_t_resize()
- * @see fl_string_maps_decrease()
- * @see fl_string_maps_decrease_by()
- * @see fl_string_maps_increase()
- * @see fl_string_maps_increase_by()
- * @see fl_string_maps_terminate()
- * @see fl_string_maps_terminate_after()
- */
-#if !defined(_di_fl_string_maps_decrease_) || !defined(_di_fl_string_maps_decrease_by_) || !defined(_di_fl_string_maps_increase_) || !defined(_di_fl_string_maps_increase_by_) || !defined(_di_fl_string_maps_terminate_) || !defined(_di_fl_string_maps_terminate_after_)
- extern f_status_t private_fl_string_maps_resize(const f_string_length_t length, f_string_maps_t *maps) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_maps_decrease_) || !defined(_di_fl_string_maps_decrease_by_) || !defined(_di_fl_string_maps_increase_) || !defined(_di_fl_string_maps_increase_by_) || !defined(_di_fl_string_maps_terminate_) || !defined(_di_fl_string_maps_terminate_after_)
-
-/**
- * Private implementation of fl_string_prepend().
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param source
- * The source string to prepend.
- * @param length
- * Length of source to append.
- * @param destination
- * The destination string the source and glue are prepended onto.
- *
- * @return
- * F_none on success.
- * F_string_too_large (with error bit) if the combined string is too large.
- *
- * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- *
- * @see memcopy()
- * @see memmove()
- *
- * @see fl_string_dynamic_mish()
- * @see fl_string_dynamic_partial_mish()
- * @see fl_string_dynamic_partial_prepend_assure()
- * @see fl_string_dynamic_partial_prepend()
- * @see fl_string_dynamic_prepend_assure()
- * @see fl_string_dynamic_prepend()
- * @see fl_string_mish()
- * @see fl_string_prepend_assure()
- * @see fl_string_prepend()
- */
-#if !defined(_di_fl_string_dynamic_mish_) || !defined(_di_fl_string_dynamic_partial_mish_) || !defined(_di_fl_string_dynamic_partial_prepend_assure_) || !defined(_di_fl_string_dynamic_partial_prepend_) || !defined(_di_fl_string_dynamic_prepend_assure_) || !defined(_di_fl_string_dynamic_prepend_) || !defined(_di_fl_string_mish_) || !defined(_di_fl_string_prepend_assure_) || !defined(_di_fl_string_prepend_)
- extern f_status_t private_fl_string_prepend(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_dynamic_mish_) || !defined(_di_fl_string_dynamic_partial_mish_) || !defined(_di_fl_string_dynamic_partial_prepend_assure_) || !defined(_di_fl_string_dynamic_partial_prepend_) || !defined(_di_fl_string_dynamic_prepend_assure_) || !defined(_di_fl_string_dynamic_prepend_) || !defined(_di_fl_string_mish_) || !defined(_di_fl_string_prepend_assure_) || !defined(_di_fl_string_prepend_)
-
-/**
- * Private implementation of fl_string_prepend_nulless().
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param source
- * The source string to prepend.
- * @param length
- * Length of source to append.
- * @param destination
- * The destination string the source and glue are prepended onto.
- *
- * @return
- * F_none on success.
- * F_string_too_large (with error bit) if the combined string is too large.
- *
- * Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- *
- * @see memcopy()
- * @see memmove()
- *
- * @see fl_string_dynamic_mish_nulless()
- * @see fl_string_dynamic_partial_mish_nulless()
- * @see fl_string_dynamic_partial_prepend_assure_nulless()
- * @see fl_string_dynamic_partial_prepend_nulless()
- * @see fl_string_dynamic_prepend_assure_nulless()
- * @see fl_string_dynamic_prepend_nulless()
- * @see fl_string_mish_nulless()
- * @see fl_string_prepend_assure_nulless()
- * @see fl_string_prepend_nulless()
- */
-#if !defined(_di_fl_string_dynamic_mish_nulless_) || !defined(_di_fl_string_dynamic_partial_mish_nulless_) || !defined(_di_fl_string_dynamic_partial_prepend_assure_nulless_) || !defined(_di_fl_string_dynamic_partial_prepend_nulless_) || !defined(_di_fl_string_dynamic_prepend_assure_nulless_) || !defined(_di_fl_string_dynamic_prepend_nulless_) || !defined(_di_fl_string_mish_nulless_) || !defined(_di_fl_string_prepend_assure_nulless_) || !defined(_di_fl_string_prepend_nulless_)
- extern f_status_t private_fl_string_prepend_nulless(const f_string_t source, f_string_length_t length, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_string_dynamic_mish_nulless_) || !defined(_di_fl_string_dynamic_partial_mish_nulless_) || !defined(_di_fl_string_dynamic_partial_prepend_assure_nulless_) || !defined(_di_fl_string_dynamic_partial_prepend_nulless_) || !defined(_di_fl_string_dynamic_prepend_assure_nulless_) || !defined(_di_fl_string_dynamic_prepend_nulless_) || !defined(_di_fl_string_mish_nulless_) || !defined(_di_fl_string_prepend_assure_nulless_) || !defined(_di_fl_string_prepend_nulless_)
-
-/**
* Private implementation of fl_string_rip(), but only the part for finding the start/stop range.
*
* Intended to be shared to each of the different implementation variations.
extern "C" {
#endif
-#ifndef _di_fl_string_append_
- f_status_t fl_string_append(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- return private_fl_string_append(source, length, destination);
- }
-#endif // _di_fl_string_append_
-
-#ifndef _di_fl_string_append_assure_
- f_status_t fl_string_append_assure(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
- if (destination->used < length) return private_fl_string_append(source, length, destination);
-
- f_string_length_t i = 1;
- f_string_length_t j = 1;
-
- while (i <= length && j <= destination->used) {
- if (!source[length - i]) {
- i++;
- continue;
- }
-
- if (!destination->string[destination->used - j]) {
- j++;
- continue;
- }
-
- if (source[length - i] != destination->string[destination->used - j]) {
- return private_fl_string_append(source, length, destination);
- }
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_append_assure_
-
-#ifndef _di_fl_string_append_assure_nulless_
- f_status_t fl_string_append_assure_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- if (destination->used < length) {
- return private_fl_string_append_nulless(source, length, destination);
- }
-
- f_string_length_t i = 1;
- f_string_length_t j = 1;
-
- while (i <= length && j <= destination->used) {
- if (!source[length - i]) {
- i++;
- continue;
- }
-
- if (!destination->string[destination->used - j]) {
- j++;
- continue;
- }
-
- if (source[length - i] != destination->string[destination->used - j]) {
- return private_fl_string_append_nulless(source, length, destination);
- }
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_append_assure_nulless_
-
-#ifndef _di_fl_string_append_nulless_
- f_status_t fl_string_append_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- return private_fl_string_append_nulless(source, length, destination);
- }
-#endif // _di_fl_string_append_nulless_
-
#ifndef _di_fl_string_compare_
f_status_t fl_string_compare(const f_string_t string1, const f_string_t string2, const f_string_length_t length1, const f_string_length_t length2) {
return private_fl_string_compare(string1, string2, 0, 0, length1, length2);
}
#endif // _di_fl_string_compare_trim_
-#ifndef _di_fl_string_dynamic_append_
- f_status_t fl_string_dynamic_append(const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- return private_fl_string_append(source.string, source.used, destination);
- }
-#endif // _di_fl_string_dynamic_append_
-
-#ifndef _di_fl_string_dynamic_append_assure_
- f_status_t fl_string_dynamic_append_assure(const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- if (destination->used < source.used) {
- return private_fl_string_append(source.string, source.used, destination);
- }
-
- f_string_length_t i = 1;
- f_string_length_t j = 1;
-
- while (i <= source.used && j <= destination->used) {
- if (!source.string[source.used - i]) {
- i++;
- continue;
- }
-
- if (!destination->string[destination->used - j]) {
- j++;
- continue;
- }
-
- if (source.string[source.used - i] != destination->string[destination->used - j]) {
- return private_fl_string_append(source.string, source.used, destination);
- }
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_append_assure_
-
-#ifndef _di_fl_string_dynamic_append_assure_nulless_
- f_status_t fl_string_dynamic_append_assure_nulless(const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- if (destination->used < source.used) {
- return private_fl_string_append_nulless(source.string, source.used, destination);
- }
-
- f_string_length_t i = 1;
- f_string_length_t j = 1;
-
- while (i <= source.used && j <= destination->used) {
- if (!source.string[source.used - i]) {
- i++;
- continue;
- }
-
- if (!destination->string[destination->used - j]) {
- j++;
- continue;
- }
-
- if (source.string[source.used - i] != destination->string[destination->used - j]) {
- return private_fl_string_append_nulless(source.string, source.used, destination);
- }
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_append_assure_nulless_
-
-#ifndef _di_fl_string_dynamic_append_nulless_
- f_status_t fl_string_dynamic_append_nulless(const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- return private_fl_string_append_nulless(source.string, source.used, destination);
- }
-#endif // _di_fl_string_dynamic_append_nulless_
-
#ifndef _di_fl_string_dynamic_compare_
f_status_t fl_string_dynamic_compare(const f_string_static_t string1, const f_string_static_t string2) {
return private_fl_string_compare(string1.string, string2.string, 0, 0, string1.used, string2.used);
}
#endif // _di_fl_string_dynamic_compare_trim_string_
-#ifndef _di_fl_string_dynamic_decrease_
- f_status_t fl_string_dynamic_decrease(f_string_dynamic_t *string) {
- #ifndef _di_level_1_parameter_checking_
- if (!string) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (string->size > 1) {
- return private_fl_string_dynamic_resize(string->size - 1, string);
- }
-
- private_fl_string_dynamic_delete(string);
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_decrease_
-
-#ifndef _di_fl_string_dynamic_decrease_by_
- f_status_t fl_string_dynamic_decrease_by(const f_string_length_t amount, f_string_dynamic_t *string) {
- #ifndef _di_level_1_parameter_checking_
- if (!amount) return F_status_set_error(F_parameter);
- if (!string) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (string->size - amount > 0) {
- return private_fl_string_dynamic_resize(string->size - amount, string);
- }
-
- private_fl_string_dynamic_delete(string);
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_decrease_by_
-
-#ifndef _di_fl_string_dynamic_delete_
- f_status_t fl_string_dynamic_delete(f_string_dynamic_t *string) {
- #ifndef _di_level_1_parameter_checking_
- if (!string) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- private_fl_string_dynamic_delete(string);
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_delete_
-
-#ifndef _di_fl_string_dynamic_mash_
- f_status_t fl_string_dynamic_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- if (glue_length && destination->used) {
- const f_status_t status = private_fl_string_append(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_append(source.string, source.used, destination);
- }
-#endif // _di_fl_string_dynamic_mash_
-
-#ifndef _di_fl_string_dynamic_mash_nulless_
- f_status_t fl_string_dynamic_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- if (glue_length && destination->used) {
- const f_status_t status = private_fl_string_append_nulless(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_append_nulless(source.string, source.used, destination);
- }
-#endif // _di_fl_string_dynamic_mash_nulless_
-
-#ifndef _di_fl_string_dynamic_mish_
- f_status_t fl_string_dynamic_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- if (glue_length && destination->used) {
- const f_status_t status = private_fl_string_prepend(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_prepend(source.string, source.used, destination);
- }
-#endif // _di_fl_string_dynamic_mish_
-
-#ifndef _di_fl_string_dynamic_mish_nulless_
- f_status_t fl_string_dynamic_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- if (glue_length && destination->used) {
- const f_status_t status = private_fl_string_prepend_nulless(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_prepend_nulless(source.string, source.used, destination);
- }
-#endif // _di_fl_string_dynamic_mish_nulless_
-
-#ifndef _di_fl_string_dynamic_partial_append_
- f_status_t fl_string_dynamic_partial_append(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- return private_fl_string_append(source.string + range.start, (range.stop - range.start) + 1, destination);
- }
-#endif // _di_fl_string_dynamic_partial_append_
-
-#ifndef _di_fl_string_dynamic_partial_append_assure_
- f_status_t fl_string_dynamic_partial_append_assure(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- const f_string_length_t length = (range.stop - range.start) + 1;
-
- if (destination->used < length) {
- return private_fl_string_append(source.string + range.start, length, destination);
- }
-
- f_string_length_t i = 1;
- f_string_length_t j = 1;
-
- while (i <= length && j <= destination->used) {
- if (!source.string[range.stop - i]) {
- i++;
- continue;
- }
-
- if (!destination->string[destination->used - j]) {
- j++;
- continue;
- }
-
- if (source.string[range.stop - i] != destination->string[destination->used - j]) {
- return private_fl_string_append(source.string + range.start, length, destination);
- }
-
- i++;
- j++;
- } // while
- }
-#endif // _di_fl_string_dynamic_partial_append_assure_
-
-#ifndef _di_fl_string_dynamic_partial_append_assure_nulless_
- f_status_t fl_string_dynamic_partial_append_assure_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- const f_string_length_t length = (range.stop - range.start) + 1;
-
- if (destination->used < length) {
- return private_fl_string_append_nulless(source.string + range.start, length, destination);
- }
-
- f_string_length_t i = 1;
- f_string_length_t j = 1;
-
- while (i <= length && j <= destination->used) {
- if (!source.string[range.stop - i]) {
- i++;
- continue;
- }
-
- if (!destination->string[destination->used - j]) {
- j++;
- continue;
- }
-
- if (source.string[range.stop - i] != destination->string[destination->used - j]) {
- return private_fl_string_append_nulless(source.string + range.start, length, destination);
- }
-
- i++;
- j++;
- } // while
- }
-#endif // _di_fl_string_dynamic_append_assure_nulless_
-
-#ifndef _di_fl_string_dynamic_partial_append_nulless_
- f_status_t fl_string_dynamic_partial_append_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- return private_fl_string_append_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
- }
-#endif // _di_fl_string_dynamic_partial_append_nulless_
-
#ifndef _di_fl_string_dynamic_partial_compare_
f_status_t fl_string_dynamic_partial_compare(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range1, const f_string_range_t range2) {
#ifndef _di_level_1_parameter_checking_
return private_fl_string_compare_except_trim(string1, string2.string, 0, range2.start, length1, range2.stop + 1, except1, except2);
}
-#endif // _di_fl_string_dynamic_partial_compare_except_trim_string_
-
-#ifndef _di_fl_string_dynamic_partial_compare_trim_
- f_status_t fl_string_dynamic_partial_compare_trim(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range1, const f_string_range_t range2) {
- #ifndef _di_level_1_parameter_checking_
- if (string1.used <= range1.stop) return F_status_set_error(F_parameter);
- if (string2.used <= range2.stop) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- return private_fl_string_compare_trim(string1.string, string2.string, range1.start, range2.start, range1.stop + 1, range2.stop + 1);
- }
-#endif // _di_fl_string_dynamic_partial_compare_trim_
-
-#ifndef _di_fl_string_dynamic_partial_compare_trim_dynamic_
- f_status_t fl_string_dynamic_partial_compare_trim_dynamic(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range2) {
- #ifndef _di_level_1_parameter_checking_
- if (string2.used <= range2.stop) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- return private_fl_string_compare_trim(string1.string, string2.string, 0, range2.start, string1.used, range2.stop + 1);
- }
-#endif // _di_fl_string_dynamic_partial_compare_trim_dynamic_
-
-#ifndef _di_fl_string_dynamic_partial_compare_trim_string_
- f_status_t fl_string_dynamic_partial_compare_trim_string(const f_string_t string1, const f_string_static_t string2, const f_string_length_t length1, const f_string_range_t range2) {
- #ifndef _di_level_1_parameter_checking_
- if (string2.used <= range2.stop) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- return private_fl_string_compare_trim(string1, string2.string, 0, range2.start, length1, range2.stop + 1);
- }
-#endif // _di_fl_string_dynamic_partial_compare_trim_string_
-
-#ifndef _di_fl_string_dynamic_partial_mash_
- f_status_t fl_string_dynamic_partial_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- if (glue_length && destination->used) {
- f_status_t status = private_fl_string_append(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_append(source.string + range.start, (range.stop - range.start) + 1, destination);
- }
-#endif // _di_fl_string_dynamic_partial_mash_
-
-#ifndef _di_fl_string_dynamic_partial_mash_nulless_
- f_status_t fl_string_dynamic_partial_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- if (glue_length && destination->used) {
- f_status_t status = private_fl_string_append_nulless(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_append_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
- }
-#endif // _di_fl_string_dynamic_partial_mash_nulless_
-
-#ifndef _di_fl_string_dynamic_partial_mish_
- f_status_t fl_string_partial_dynamic_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- if (glue_length && destination->used) {
- f_status_t status = private_fl_string_prepend(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_prepend(source.string + range.start, (range.stop - range.start) + 1, destination);
- }
-#endif // _di_fl_string_dynamic_partial_mish_
-
-#ifndef _di_fl_string_dynamic_partial_mish_nulless_
- f_status_t fl_string_dynamic_partial_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- if (glue_length && destination->used) {
- f_status_t status = private_fl_string_prepend_nulless(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_prepend_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
- }
-#endif // _di_fl_string_dynamic_partial_mish_nulless_
-
-#ifndef _di_fl_string_dynamic_partial_prepend_
- f_status_t fl_string_dynamic_partial_prepend(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- return private_fl_string_prepend(source.string + range.start, (range.stop - range.start) + 1, destination);
- }
-#endif // _di_fl_string_dynamic_partial_prepend_
-
-#ifndef _di_fl_string_dynamic_partial_prepend_assure_
- f_status_t fl_string_dynamic_partial_prepend_assure(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- const f_string_length_t length = (range.stop - range.start) + 1;
-
- if (destination->used < length) {
- return private_fl_string_prepend(source.string + range.start, length, destination);
- }
-
- f_string_length_t i = 0;
- f_string_length_t j = 0;
-
- while (i < length && j < destination->used) {
- if (!source.string[i + range.start]) {
- i++;
- continue;
- }
-
- if (!destination->string[j]) {
- j++;
- continue;
- }
-
- if (source.string[i + range.start] != destination->string[i]) {
- return private_fl_string_prepend(source.string + range.start, length, destination);
- }
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_partial_prepend_assure_
-
-#ifndef _di_fl_string_dynamic_partial_prepend_assure_nulless_
- f_status_t fl_string_dynamic_partial_prepend_assure_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- const f_string_length_t length = (range.stop - range.start) + 1;
-
- if (destination->used < length) {
- return private_fl_string_prepend_nulless(source.string + range.start, length, destination);
- }
-
- f_string_length_t i = 0;
- f_string_length_t j = 0;
-
- while (i < length && j < destination->used) {
- if (!source.string[i + range.start]) {
- i++;
- continue;
- }
-
- if (!destination->string[j]) {
- j++;
- continue;
- }
-
- if (source.string[i + range.start] != destination->string[i]) {
- return private_fl_string_prepend_nulless(source.string + range.start, length, destination);
- }
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_partial_prepend_assure_nulless
-
-#ifndef _di_fl_string_dynamic_partial_prepend_nulless_
- f_status_t fl_string_dynamic_partial_prepend_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (source.used <= range.stop) return F_status_set_error(F_parameter);
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
- if (range.start > range.stop) return F_data_not_stop;
-
- return private_fl_string_prepend_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
- }
-#endif // _di_fl_string_dynamic_partial_prepend_nulless
-
-#ifndef _di_fl_string_dynamic_prepend_
- f_status_t fl_string_dynamic_prepend(const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- return private_fl_string_prepend(source.string, source.used, destination);
- }
-#endif // _di_fl_string_dynamic_prepend_
-
-#ifndef _di_fl_string_dynamic_prepend_assure_
- f_status_t fl_string_dynamic_prepend_assure(const f_string_static_t source, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!source.used) return F_data_not_eos;
-
- if (destination->used < source.used) {
- return private_fl_string_prepend(source.string, source.used, destination);
- }
-
- f_string_length_t i = 0;
- f_string_length_t j = 0;
-
- while (i < source.used && j < destination->used) {
- if (!source.string[i]) {
- i++;
- continue;
- }
-
- if (!destination->string[j]) {
- j++;
- continue;
- }
-
- if (source.string[i] != destination->string[i]) {
- return private_fl_string_prepend(source.string, source.used, destination);
- }
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_prepend_assure_
+#endif // _di_fl_string_dynamic_partial_compare_except_trim_string_
-#ifndef _di_fl_string_dynamic_prepend_assure_nulless_
- f_status_t fl_string_dynamic_prepend_assure_nulless(const f_string_static_t source, f_string_dynamic_t *destination) {
+#ifndef _di_fl_string_dynamic_partial_compare_trim_
+ f_status_t fl_string_dynamic_partial_compare_trim(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range1, const f_string_range_t range2) {
#ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
+ if (string1.used <= range1.stop) return F_status_set_error(F_parameter);
+ if (string2.used <= range2.stop) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
- if (!source.used) return F_data_not_eos;
-
- if (destination->used < source.used) {
- return private_fl_string_prepend_nulless(source.string, source.used, destination);
- }
-
- f_string_length_t i = 0;
- f_string_length_t j = 0;
-
- while (i < source.used && j < destination->used) {
- if (!source.string[i]) {
- i++;
- continue;
- }
-
- if (!destination->string[j]) {
- j++;
- continue;
- }
-
- if (source.string[i] != destination->string[i]) {
- return private_fl_string_prepend_nulless(source.string, source.used, destination);
- }
+ return private_fl_string_compare_trim(string1.string, string2.string, range1.start, range2.start, range1.stop + 1, range2.stop + 1);
+ }
+#endif // _di_fl_string_dynamic_partial_compare_trim_
- i++;
- j++;
- } // while
+#ifndef _di_fl_string_dynamic_partial_compare_trim_dynamic_
+ f_status_t fl_string_dynamic_partial_compare_trim_dynamic(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range2) {
+ #ifndef _di_level_1_parameter_checking_
+ if (string2.used <= range2.stop) return F_status_set_error(F_parameter);
+ #endif // _di_level_1_parameter_checking_
- return F_none;
+ return private_fl_string_compare_trim(string1.string, string2.string, 0, range2.start, string1.used, range2.stop + 1);
}
-#endif // _di_fl_string_dynamic_prepend_assure_nulless_
+#endif // _di_fl_string_dynamic_partial_compare_trim_dynamic_
-#ifndef _di_fl_string_dynamic_prepend_nulless_
- f_status_t fl_string_dynamic_prepend_nulless(const f_string_static_t source, f_string_dynamic_t *destination) {
+#ifndef _di_fl_string_dynamic_partial_compare_trim_string_
+ f_status_t fl_string_dynamic_partial_compare_trim_string(const f_string_t string1, const f_string_static_t string2, const f_string_length_t length1, const f_string_range_t range2) {
#ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
+ if (string2.used <= range2.stop) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
- if (!source.used) return F_data_not_eos;
-
- return private_fl_string_prepend_nulless(source.string, source.used, destination);
+ return private_fl_string_compare_trim(string1, string2.string, 0, range2.start, length1, range2.stop + 1);
}
-#endif // _di_fl_string_dynamic_prepend_nulless_
+#endif // _di_fl_string_dynamic_partial_compare_trim_string_
#ifndef _di_fl_string_dynamic_rip_
f_status_t fl_string_dynamic_rip(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
if (!source.used) return F_data_not_eos;
if (range.start > range.stop) return F_data_not_stop;
- return private_fl_string_append(source.string + begin, (end - begin) + 1, destination);
+ return f_string_append(source.string + begin, (end - begin) + 1, destination);
}
#endif // _di_fl_string_dynamic_rip_
if (!source.used) return F_data_not_eos;
if (range.start > range.stop) return F_data_not_stop;
- return private_fl_string_append_nulless(source.string + begin, (end - begin) + 1, destination);
+ return f_string_append_nulless(source.string + begin, (end - begin) + 1, destination);
}
#endif // _di_fl_string_dynamic_rip_nulless_
-#ifndef _di_fl_string_dynamic_increase_
- f_status_t fl_string_dynamic_increase(f_string_dynamic_t *string) {
- #ifndef _di_level_1_parameter_checking_
- if (!string) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (string->used + 1 > string->size) {
- f_array_length_t size = string->used + f_memory_default_allocation_step;
-
- if (size > f_string_length_t_size) {
- if (string->used + 1 > f_string_length_t_size) {
- return F_status_set_error(F_string_too_large);
- }
-
- size = f_string_length_t_size;
- }
-
- return private_fl_string_dynamic_resize(size, string);
- }
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_increase_
-
-#ifndef _di_fl_string_dynamic_increase_by_
- f_status_t fl_string_dynamic_increase_by(const f_string_length_t amount, f_string_dynamic_t *string) {
- #ifndef _di_level_1_parameter_checking_
- if (!string) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- return private_fl_string_dynamic_increase_by(amount, string);
- }
-#endif // _di_fl_string_dynamic_increase_by_
-
#ifndef _di_fl_string_dynamic_seek_line_
f_status_t fl_string_dynamic_seek_line(const f_string_t string, f_string_range_t *range) {
#ifndef _di_level_1_parameter_checking_
}
#endif // _di_fl_string_dynamic_seek_to_utf_character_
-#ifndef _di_fl_string_dynamic_terminate_
- f_status_t fl_string_dynamic_terminate(f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- if (destination->used > destination->size) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!destination->used && destination->size && !destination->string[destination->used - 1]) {
- return F_none;
- }
-
- if (destination->used == f_string_length_t_size) {
- return F_status_set_error(F_string_too_large);
- }
-
- const f_string_length_t total = destination->used + 1;
-
- if (total > destination->size) {
- const f_status_t status = private_fl_string_dynamic_resize(total, destination);
- if (F_status_is_error(status)) return status;
- }
-
- destination->string[destination->used] = 0;
- destination->used = total;
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_terminate_
-
-#ifndef _di_fl_string_dynamic_terminate_after_
- f_status_t fl_string_dynamic_terminate_after(f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- if (destination->used > destination->size) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (destination->used) {
- for (; destination->used; destination->used--) {
- if (!destination->string[destination->used - 1]) continue;
- break;
- } // for
- }
-
- if (destination->used == f_string_length_t_size) {
- return F_status_set_error(F_string_too_large);
- }
-
- const f_string_length_t total = destination->used + 1;
-
- if (total > destination->size) {
- const f_status_t status = private_fl_string_dynamic_resize(total, destination);
- if (F_status_is_error(status)) return status;
- }
-
- destination->string[destination->used] = 0;
- destination->used = total - 1;
-
- return F_none;
- }
-#endif // _di_fl_string_dynamic_terminate_after_
-
-#ifndef _di_fl_string_dynamics_decrease_
- f_status_t fl_string_dynamics_decrease(f_string_dynamics_t *strings) {
- #ifndef _di_level_1_parameter_checking_
- if (!strings) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (strings->size > 1) {
- return private_fl_string_dynamics_resize(strings->size - 1, strings);
- }
-
- private_fl_string_dynamics_delete(strings);
-
- return F_none;
- }
-#endif // _di_fl_string_dynamics_decrease_
-
-#ifndef _di_fl_string_dynamics_decrease_by_
- f_status_t fl_string_dynamics_decrease_by(const f_array_length_t amount, f_string_dynamics_t *strings) {
- #ifndef _di_level_1_parameter_checking_
- if (!amount) return F_status_set_error(F_parameter);
- if (!strings) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (strings->size - amount > 0) {
- return private_fl_string_dynamics_resize(strings->size - amount, strings);
- }
-
- private_fl_string_dynamics_delete(strings);
-
- return F_none;
- }
-#endif // _di_fl_string_dynamics_decrease_by_
-
-#ifndef _di_fl_string_dynamics_delete_
- f_status_t fl_string_dynamics_delete(f_string_dynamics_t *strings) {
- #ifndef _di_level_1_parameter_checking_
- if (!strings) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- private_fl_string_dynamics_delete(strings);
-
- return F_none;
- }
-#endif // _di_fl_string_dynamics_delete_
-
-#ifndef _di_fl_string_dynamics_increase_
- f_status_t fl_string_dynamics_increase(f_string_dynamics_t *strings) {
- #ifndef _di_level_1_parameter_checking_
- if (!strings) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (strings->used + 1 > strings->size) {
- f_array_length_t size = strings->used + f_memory_default_allocation_step;
-
- if (size > f_array_length_t_size) {
- if (strings->used + 1 > f_array_length_t_size) {
- return F_status_set_error(F_array_too_large);
- }
-
- size = f_array_length_t_size;
- }
-
- return private_fl_string_dynamics_resize(size, strings);
- }
-
- return F_none;
- }
-#endif // _di_fl_string_dynamics_increase_
-
-#ifndef _di_fl_string_dynamics_increase_by_
- f_status_t fl_string_dynamics_increase_by(const f_array_length_t amount, f_string_dynamics_t *strings) {
- #ifndef _di_level_1_parameter_checking_
- if (!strings) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (strings->used + amount > strings->size) {
- if (strings->used + amount > f_array_length_t_size) {
- return F_status_set_error(F_array_too_large);
- }
-
- return private_fl_string_dynamics_resize(strings->used + amount, strings);
- }
-
- return F_none;
- }
-#endif // _di_fl_string_dynamics_increase_by_
-
-#ifndef _di_fl_string_maps_decrease_
- f_status_t fl_string_maps_decrease(f_string_maps_t *maps) {
- #ifndef _di_level_1_parameter_checking_
- if (!maps) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (maps->size > 1) {
- return private_fl_string_maps_resize(maps->size - 1, maps);
- }
-
- private_fl_string_maps_delete(maps);
-
- return F_none;
- }
-#endif // _di_fl_string_maps_decrease_
-
-#ifndef _di_fl_string_maps_decrease_by_
- f_status_t fl_string_maps_decrease_by(const f_array_length_t amount, f_string_maps_t *maps) {
- #ifndef _di_level_1_parameter_checking_
- if (!amount) return F_status_set_error(F_parameter);
- if (!maps) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (maps->size - amount > 0) {
- return private_fl_string_maps_resize(maps->size - amount, maps);
- }
-
- private_fl_string_maps_delete(maps);
-
- return F_none;
- }
-#endif // _di_fl_string_maps_decrease_by_
-
-#ifndef _di_fl_string_maps_delete_
- f_status_t fl_string_maps_delete(f_string_maps_t *maps) {
- #ifndef _di_level_1_parameter_checking_
- if (!maps) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- private_fl_string_maps_delete(maps);
-
- return F_none;
- }
-#endif // _di_fl_string_maps_delete_
-
-#ifndef _di_fl_string_maps_increase_
- f_status_t fl_string_maps_increase(f_string_maps_t *maps) {
- #ifndef _di_level_1_parameter_checking_
- if (!maps) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (maps->used + 1 > maps->size) {
- f_array_length_t size = maps->used + f_memory_default_allocation_step;
-
- if (size > f_array_length_t_size) {
- if (maps->used + 1 > f_array_length_t_size) {
- return F_status_set_error(F_array_too_large);
- }
-
- size = f_array_length_t_size;
- }
-
- return private_fl_string_maps_resize(size, maps);
- }
-
- return F_none;
- }
-#endif // _di_fl_string_maps_increase_
-
-#ifndef _di_fl_string_maps_increase_by_
- f_status_t fl_string_maps_increase_by(const f_array_length_t amount, f_string_maps_t *maps) {
- #ifndef _di_level_1_parameter_checking_
- if (!amount) return F_status_set_error(F_parameter);
- if (!maps) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (maps->used + amount > maps->size) {
- if (maps->used + amount > f_array_length_t_size) {
- return F_status_set_error(F_array_too_large);
- }
-
- return private_fl_string_maps_resize(maps->used + amount, maps);
- }
-
- return F_none;
- }
-#endif // _di_fl_string_maps_increase_by_
-
-#ifndef _di_fl_string_mash_
- f_status_t fl_string_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- if (glue_length && destination->used) {
- f_status_t status = private_fl_string_append(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_append(source, length, destination);
- }
-#endif // _di_fl_string_mash_
-
-#ifndef _di_fl_string_mash_nulless_
- f_status_t fl_string_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- if (glue_length && destination->used) {
- f_status_t status = private_fl_string_append_nulless(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_append_nulless(source, length, destination);
- }
-#endif // _di_fl_string_mash_nulless_
-
-#ifndef _di_fl_string_mish_
- f_status_t fl_string_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- if (glue_length && destination->used) {
- f_status_t status = private_fl_string_prepend(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_prepend(source, length, destination);
- }
-#endif // _di_fl_string_mish_
-
-#ifndef _di_fl_string_mish_nulless_
- f_status_t fl_string_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- if (glue_length && destination->used) {
- f_status_t status = private_fl_string_prepend_nulless(glue, glue_length, destination);
- if (F_status_is_error(status)) return status;
- }
-
- return private_fl_string_prepend_nulless(source, length, destination);
- }
-#endif // _di_fl_string_mish_nulless_
-
-#ifndef _di_fl_string_prepend_
- f_status_t fl_string_prepend(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- return private_fl_string_prepend(source, length, destination);
- }
-#endif // _di_fl_string_prepend_
-
-#ifndef _di_fl_string_prepend_assure_
- f_status_t fl_string_prepend_assure(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
- if (destination->used < length) return private_fl_string_prepend(source, length, destination);
-
- f_string_length_t i = 0;
- f_string_length_t j = 0;
-
- while (i < length && j < destination->used) {
- if (!source[i]) {
- i++;
- continue;
- }
-
- if (!destination->string[j]) {
- j++;
- continue;
- }
-
- if (source[i] != destination->string[i]) return private_fl_string_prepend(source, length, destination);
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_prepend_assure_
-
-#ifndef _di_fl_string_prepend_assure_nulless_
- f_status_t fl_string_prepend_assure_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
- if (destination->used < length) return private_fl_string_prepend_nulless(source, length, destination);
-
- f_string_length_t i = 0;
- f_string_length_t j = 0;
-
- while (i < length && j < destination->used) {
- if (!source[i]) {
- i++;
- continue;
- }
-
- if (!destination->string[j]) {
- j++;
- continue;
- }
-
- if (source[i] != destination->string[i]) return private_fl_string_prepend_nulless(source, length, destination);
-
- i++;
- j++;
- } // while
-
- return F_none;
- }
-#endif // _di_fl_string_prepend_assure_nulless_
-
-#ifndef _di_fl_string_prepend_nulless_
- f_status_t fl_string_prepend_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
- #ifndef _di_level_1_parameter_checking_
- if (!destination) return F_status_set_error(F_parameter);
- #endif // _di_level_1_parameter_checking_
-
- if (!length) return F_data_not_eos;
-
- return private_fl_string_prepend_nulless(source, length, destination);
- }
-#endif // _di_fl_string_prepend_nulless_
-
#ifndef _di_fl_string_rip_
f_status_t fl_string_rip(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination) {
#ifndef _di_level_1_parameter_checking_
if (F_status_is_error(status)) return status;
if (status == F_data_not) return status;
- return private_fl_string_append(source + begin, (end - begin) + 1, destination);
+ return f_string_append(source + begin, (end - begin) + 1, destination);
}
#endif // _di_fl_string_rip_
if (F_status_is_error(status)) return status;
if (status == F_data_not) return status;
- return private_fl_string_append_nulless(source + begin, (end - begin) + 1, destination);
+ return f_string_append_nulless(source + begin, (end - begin) + 1, destination);
}
#endif // _di_fl_string_rip_nulless_
#endif
/**
- * Append the source string onto the destination.
- *
- * @param source
- * The source string to append.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_append_
- extern f_status_t fl_string_append(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_append_
-
-/**
- * Append the source string onto the destination, but only if the string is not already at the end.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- *
- * @param source
- * The source string to append.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_append_assure_
- extern f_status_t fl_string_append_assure(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_append_assure_
-
-/**
- * Append the source string onto the destination, but only if the string is not already at the end.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- * Skips over NULL characters from source when appending.
- *
- * @param source
- * The source string to append.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_append_assure_nulless_
- extern f_status_t fl_string_append_assure_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_append_assure_nulless_
-
-/**
- * Append the source string onto the destination.
- *
- * Skips over NULL characters from source when appending.
- *
- * @param source
- * The source string to append.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_append_nulless_
- extern f_status_t fl_string_append_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_append_nulless_
-
-/**
* Compare two strings, similar to strncmp().
*
* This does not stop on NULL.
#endif // _di_fl_string_compare_trim_
/**
- * Append the source string onto the destination.
- *
- * @param source
- * The source string to append.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_append_
- extern f_status_t fl_string_dynamic_append(const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_append_
-
-/**
- * Append the source string onto the destination.
- *
- * @param source
- * The source string to append.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_append_assure_
- extern f_status_t fl_string_dynamic_append_assure(const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_append_assure_
-
-/**
- * Append the source string onto the destination.
- *
- * Skips over NULL characters from source when appending.
- *
- * @param source
- * The source string to append.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_append_assure_nulless_
- extern f_status_t fl_string_dynamic_append_assure_nulless(const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_append_assure_nulless_
-
-/**
- * Append the source string onto the destination.
- *
- * Skips over NULL characters from source when appending.
- *
- * @param source
- * The source string to append.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_append_nulless_
- extern f_status_t fl_string_dynamic_append_nulless(const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_append_nulless_
-
-/**
* Compare two strings, similar to strncmp().
*
* This does not stop on NULL.
#endif // _di_fl_string_dynamic_compare_trim_string_
/**
- * Resize the dynamic string to a smaller size, by 1.
+ * Compare two strings, similar to strncmp(), but restricted to the given ranges.
*
- * This will shrink the size by size - 1.
- * This will not shrink the size to less than 0.
+ * This does not stop on NULL.
+ * NULL characters are ignored.
*
- * @param string
- * The string to resize.
+ * @param string1
+ * String to compare.
+ * @param string2
+ * String to compare.
+ * @param range1
+ * A range within the string1 to restrict the comparison to.
+ * @param range2
+ * A range within the string2 to restrict the comparison to.
*
* @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
+ * F_equal_to when both strings equal.
+ * F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
*/
-#ifndef _di_fl_string_dynamic_decrease_
- extern f_status_t fl_string_dynamic_decrease(f_string_dynamic_t *string);
-#endif // _di_fl_string_dynamic_decrease_
+#ifndef _di_fl_string_dynamic_partial_compare_
+ extern f_status_t fl_string_dynamic_partial_compare(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range1, const f_string_range_t range2);
+#endif // _di_fl_string_dynamic_partial_compare_
/**
- * Resize the dynamic string to a smaller size.
+ * Compare two strings, similar to strncmp(), but restricted to the given ranges.
*
- * This will resize making the string smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
+ * This does not stop on NULL.
+ * NULL characters are ignored.
+ * All 1-byte characters in except1 and except2 are ignored.
*
- * @param amount
- * A positive number representing how much to decrease the size by.
- * @param string
- * The string to resize.
+ * @param string1
+ * String to compare.
+ * @param string2
+ * String to compare.
+ * @param range1
+ * A range within the string1 to restrict the comparison to.
+ * @param range2
+ * A range within the string2 to restrict the comparison to.
+ * @param except1
+ * A set of locations within string1 to ignore.
+ * This assumes/requires that the locations be in linear order.
+ * @param except2
+ * A set of locations within string2 to ignore.
+ * This assumes/requires that the locations be in linear order.
*
* @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
+ * F_equal_to when both strings equal.
+ * F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
*/
-#ifndef _di_fl_string_dynamic_decrease_by_
- extern f_status_t fl_string_dynamic_decrease_by(const f_string_length_t amount, f_string_dynamic_t *string);
-#endif // _di_fl_string_dynamic_decrease_by_
+#ifndef _di_fl_string_dynamic_partial_compare_except_
+ extern f_status_t fl_string_dynamic_partial_compare_except(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range1, const f_string_range_t range2, const f_string_lengths_t except1, const f_string_lengths_t except2);
+#endif // _di_fl_string_dynamic_partial_compare_except_
/**
- * Delete the dynamic string.
+ * Compare two strings, similar to strncmp(), but restricted to the given range for the second string.
*
- * @param string
- * The string to delete.
+ * This does not stop on NULL.
+ * NULL characters are ignored.
+ * All 1-byte characters in except1 and except2 are ignored.
+ *
+ * @param string1
+ * String to compare.
+ * @param string2
+ * String to compare.
+ * @param range2
+ * A range within the string2 to restrict the comparison to.
+ * @param except1
+ * A set of locations within string1 to ignore.
+ * This assumes/requires that the locations be in linear order.
+ * @param except2
+ * A set of locations within string2 to ignore.
+ * This assumes/requires that the locations be in linear order.
*
* @return
- * F_none on success.
+ * F_equal_to when both strings equal.
+ * F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
*/
-#ifndef _di_fl_string_dynamic_delete_
- extern f_status_t fl_string_dynamic_delete(f_string_dynamic_t *string);
-#endif // _di_fl_string_dynamic_delete_
+#ifndef _di_fl_string_dynamic_partial_compare_except_dynamic_
+ extern f_status_t fl_string_dynamic_partial_compare_except_dynamic(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range2, const f_string_lengths_t except1, const f_string_lengths_t except2);
+#endif // _di_fl_string_dynamic_partial_compare_except_dynamic_
/**
- * Append the source string onto the destination with the glue in between.
+ * Compare two strings, similar to strncmp(), but restricted to the given range for the second string.
+ *
+ * This operates with the first string being a traditional string.
*
- * If the destination string is empty, then no glue is appended.
+ * This does not stop on NULL.
+ * NULL characters are ignored.
+ * All 1-byte characters in except1 and except2 are ignored.
*
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param destination
- * The destination string the source and glue are appended onto.
+ * @param string1
+ * String to compare.
+ * @param string2
+ * String to compare.
+ * @param length1
+ * The length of string1.
+ * @param range2
+ * A range within the string2 to restrict the comparison to.
+ * @param except1
+ * A set of locations within string1 to ignore.
+ * This assumes/requires that the locations be in linear order.
+ * @param except2
+ * A set of locations within string2 to ignore.
+ * This assumes/requires that the locations be in linear order.
*
* @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
+ * F_equal_to when both strings equal.
+ * F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
*/
-#ifndef _di_fl_string_dynamic_mash_
- extern f_status_t fl_string_dynamic_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_mash_
+#ifndef _di_fl_string_dynamic_partial_compare_except_string_
+ extern f_status_t fl_string_dynamic_partial_compare_except_string(const f_string_t string1, const f_string_static_t string2, const f_string_length_t length1, const f_string_range_t range2, const f_string_lengths_t except1, const f_string_lengths_t except2);
+#endif // _di_fl_string_dynamic_partial_compare_except_string_
/**
- * Append the source string onto the destination with the glue in between.
- *
- * If the destination string is empty, then no glue is appended.
+ * Compare two strings, similar to strncmp(), but restricted to the given range for the second string.
*
- * Skips over NULL characters from glue and source when appending.
+ * This does not stop on NULL.
+ * NULL characters are ignored.
+ * Ignores leading and trailing whitespace.
+ * All 1-byte characters in except1 and except2 are ignored.
*
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param destination
- * The destination string the source and glue are appended onto.
+ * @param string1
+ * String to compare.
+ * @param string2
+ * String to compare.
+ * @param range2
+ * A range within the string2 to restrict the comparison to.
+ * @param except1
+ * A set of locations within string1 to ignore.
+ * This assumes/requires that the locations be in linear order.
+ * @param except2
+ * A set of locations within string2 to ignore.
+ * This assumes/requires that the locations be in linear order.
*
* @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
+ * F_equal_to when both strings equal.
+ * F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
+ *
+ * Errors (with error bit) from: f_utf_is_whitespace().
+ *
+ * @see f_utf_is_whitespace()
*/
-#ifndef _di_fl_string_dynamic_mash_nulless_
- extern f_status_t fl_string_dynamic_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_mash_nulless_
+#ifndef _di_fl_string_dynamic_partial_compare_except_trim_dynamic_
+ extern f_status_t fl_string_dynamic_partial_compare_except_trim_dynamic(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range2, const f_string_lengths_t except1, const f_string_lengths_t except2);
+#endif // _di_fl_string_dynamic_partial_compare_except_trim_dynamic_
/**
- * Prepend the source string onto the destination with the glue in between.
+ * Compare two strings, similar to strncmp(), but restricted to the given range for the second string.
*
- * If the destination string is empty, then no glue is appended.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_mish_
- extern f_status_t fl_string_dynamic_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_mish_
-
-/**
- * Prepend the source string onto the destination with the glue in between.
- *
- * If the destination string is empty, then no glue is appended.
- *
- * Skips over NULL characters from glue and source when appending.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_mish_nulless_
- extern f_status_t fl_string_dynamic_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_mish_nulless_
-
-/**
- * Append the source string onto the destination, but restricted to the given range.
- *
- * @param source
- * The source string to append.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_append_
- extern f_status_t fl_string_dynamic_partial_append(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_append_
-
-/**
- * Append the source string onto the destination, but only if the string is not already at the end and restricted to the given range
- *
- * This ignores NULL characters when comparing both the source and the destination.
- *
- * @param source
- * The source string to append.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_append_assure_
- extern f_status_t fl_string_dynamic_partial_append_assure(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_append_assure_
-
-/**
- * Append the source string onto the destination, but only if the string is not already at the end and restricted to the given range
- *
- * This ignores NULL characters when comparing both the source and the destination.
- *
- * Skips over NULL characters from source when appending.
- *
- * @param source
- * The source string to append.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_append_assure_nulless_
- extern f_status_t fl_string_dynamic_partial_append_assure_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_append_assure_nulless_
-
-/**
- * Append the source string onto the destination, but restricted to the given range.
- *
- * Skips over NULL characters from source when appending.
- *
- * @param source
- * The source string to append.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source is appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_append_nulless_
- extern f_status_t fl_string_dynamic_partial_append_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_append_nulless_
-
-/**
- * Compare two strings, similar to strncmp(), but restricted to the given ranges.
- *
- * This does not stop on NULL.
- * NULL characters are ignored.
- *
- * @param string1
- * String to compare.
- * @param string2
- * String to compare.
- * @param range1
- * A range within the string1 to restrict the comparison to.
- * @param range2
- * A range within the string2 to restrict the comparison to.
- *
- * @return
- * F_equal_to when both strings equal.
- * F_equal_to_not when both strings do not equal.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_dynamic_partial_compare_
- extern f_status_t fl_string_dynamic_partial_compare(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range1, const f_string_range_t range2);
-#endif // _di_fl_string_dynamic_partial_compare_
-
-/**
- * Compare two strings, similar to strncmp(), but restricted to the given ranges.
- *
- * This does not stop on NULL.
- * NULL characters are ignored.
- * All 1-byte characters in except1 and except2 are ignored.
- *
- * @param string1
- * String to compare.
- * @param string2
- * String to compare.
- * @param range1
- * A range within the string1 to restrict the comparison to.
- * @param range2
- * A range within the string2 to restrict the comparison to.
- * @param except1
- * A set of locations within string1 to ignore.
- * This assumes/requires that the locations be in linear order.
- * @param except2
- * A set of locations within string2 to ignore.
- * This assumes/requires that the locations be in linear order.
- *
- * @return
- * F_equal_to when both strings equal.
- * F_equal_to_not when both strings do not equal.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_dynamic_partial_compare_except_
- extern f_status_t fl_string_dynamic_partial_compare_except(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range1, const f_string_range_t range2, const f_string_lengths_t except1, const f_string_lengths_t except2);
-#endif // _di_fl_string_dynamic_partial_compare_except_
-
-/**
- * Compare two strings, similar to strncmp(), but restricted to the given range for the second string.
- *
- * This does not stop on NULL.
- * NULL characters are ignored.
- * All 1-byte characters in except1 and except2 are ignored.
- *
- * @param string1
- * String to compare.
- * @param string2
- * String to compare.
- * @param range2
- * A range within the string2 to restrict the comparison to.
- * @param except1
- * A set of locations within string1 to ignore.
- * This assumes/requires that the locations be in linear order.
- * @param except2
- * A set of locations within string2 to ignore.
- * This assumes/requires that the locations be in linear order.
- *
- * @return
- * F_equal_to when both strings equal.
- * F_equal_to_not when both strings do not equal.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_dynamic_partial_compare_except_dynamic_
- extern f_status_t fl_string_dynamic_partial_compare_except_dynamic(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range2, const f_string_lengths_t except1, const f_string_lengths_t except2);
-#endif // _di_fl_string_dynamic_partial_compare_except_dynamic_
-
-/**
- * Compare two strings, similar to strncmp(), but restricted to the given range for the second string.
- *
- * This operates with the first string being a traditional string.
- *
- * This does not stop on NULL.
- * NULL characters are ignored.
- * All 1-byte characters in except1 and except2 are ignored.
- *
- * @param string1
- * String to compare.
- * @param string2
- * String to compare.
- * @param length1
- * The length of string1.
- * @param range2
- * A range within the string2 to restrict the comparison to.
- * @param except1
- * A set of locations within string1 to ignore.
- * This assumes/requires that the locations be in linear order.
- * @param except2
- * A set of locations within string2 to ignore.
- * This assumes/requires that the locations be in linear order.
- *
- * @return
- * F_equal_to when both strings equal.
- * F_equal_to_not when both strings do not equal.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_dynamic_partial_compare_except_string_
- extern f_status_t fl_string_dynamic_partial_compare_except_string(const f_string_t string1, const f_string_static_t string2, const f_string_length_t length1, const f_string_range_t range2, const f_string_lengths_t except1, const f_string_lengths_t except2);
-#endif // _di_fl_string_dynamic_partial_compare_except_string_
-
-/**
- * Compare two strings, similar to strncmp(), but restricted to the given range for the second string.
- *
- * This does not stop on NULL.
- * NULL characters are ignored.
- * Ignores leading and trailing whitespace.
- * All 1-byte characters in except1 and except2 are ignored.
- *
- * @param string1
- * String to compare.
- * @param string2
- * String to compare.
- * @param range2
- * A range within the string2 to restrict the comparison to.
- * @param except1
- * A set of locations within string1 to ignore.
- * This assumes/requires that the locations be in linear order.
- * @param except2
- * A set of locations within string2 to ignore.
- * This assumes/requires that the locations be in linear order.
- *
- * @return
- * F_equal_to when both strings equal.
- * F_equal_to_not when both strings do not equal.
- * F_parameter (with error bit) if a parameter is invalid.
- *
- * Errors (with error bit) from: f_utf_is_whitespace().
- *
- * @see f_utf_is_whitespace()
- */
-#ifndef _di_fl_string_dynamic_partial_compare_except_trim_dynamic_
- extern f_status_t fl_string_dynamic_partial_compare_except_trim_dynamic(const f_string_static_t string1, const f_string_static_t string2, const f_string_range_t range2, const f_string_lengths_t except1, const f_string_lengths_t except2);
-#endif // _di_fl_string_dynamic_partial_compare_except_trim_dynamic_
-
-/**
- * Compare two strings, similar to strncmp(), but restricted to the given range for the second string.
- *
- * This operates with the first string being a traditional string.
+ * This operates with the first string being a traditional string.
*
* This does not stop on NULL.
* NULL characters are ignored.
#endif // _di_fl_string_dynamic_partial_compare_trim_
/**
- * Append the source string onto the destination with the glue in between, but restricted to the given range.
+ * Allocate a new string from the provided range in the buffer.
*
- * If the destination string is empty, then no glue is appended.
+ * Ignores leading and trailing whitespace.
+ * Ignores leading and trailing NULL characters.
+ * As a result, resulting size may be smaller than requested range.
*
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
* @param source
- * The source string to append.
+ * The buffer to rip from.
* @param range
- * A range within the source to restrict the copy from.
+ * A range within the buffer representing the string to rip.
* @param destination
- * The destination string the source and glue are appended onto.
+ * The new string, which will be allocated or reallocated as necessary.
*
* @return
* F_none on success.
* F_parameter (with error bit) if a parameter is invalid.
* F_string_too_large (with error bit) if the combined string is too large.
*/
-#ifndef _di_fl_string_dynamic_partial_mash_
- extern f_status_t fl_string_dynamic_partial_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_mash_
-
-/**
- * Append the source string onto the destination with the glue in between, but restricted to the given range.
- *
- * If the destination string is empty, then no glue is appended.
- *
- * Skips over NULL characters from glue and source when appending.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_mash_nulless_
- extern f_status_t fl_string_dynamic_partial_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_mash_nulless_
-
-/**
- * Prepend the source string onto the destination with the glue in between, but restricted to the given range.
- *
- * If the destination string is empty, then no glue is appended.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_mish_
- extern f_status_t fl_string_dynamic_partial_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_mish_
-
-/**
- * Prepend the source string onto the destination with the glue in between, but restricted to the given range.
- *
- * If the destination string is empty, then no glue is appended.
- *
- * Skips over NULL characters from glue and source when appending.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_mish_nulless_
- extern f_status_t fl_string_dynamic_partial_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_mish_nulless_
-
-/**
- * Prepend the source string onto the destination, but restricted to the given range.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * @param source
- * The source string to prepend.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_prepend_
- extern f_status_t fl_string_dynamic_partial_prepend(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_prepend_
-
-/**
- * Prepend the source string onto the destination, but only if the string is not already at the end and restricted to the given range
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- *
- * @param source
- * The source string to prepend.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_prepend_assure_
- extern f_status_t fl_string_dynamic_partial_prepend_assure(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_prepend_assure_
+#ifndef _di_fl_string_dynamic_rip_
+ extern f_status_t fl_string_dynamic_rip(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_fl_string_dynamic_rip_
/**
- * Prepend the source string onto the destination, but only if the string is not already at the end and restricted to the given range
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- *
- * @param source
- * The source string to prepend.
- * @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source is prepended onto.
+ * Allocate a new string from the provided range in the buffer.
*
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_prepend_assure_nulless_
- extern f_status_t fl_string_dynamic_partial_prepend_assure_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_prepend_assure_nulless_
-
-/**
- * Prepend the source string onto the destination, but restricted to the given range.
+ * Ignores leading and trailing whitespace.
+ * Ignores leading and trailing NULL characters.
+ * As a result, resulting size may be smaller than requested range.
*
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
+ * Skips over NULL characters from source when appending.
*
* @param source
- * The source string to prepend.
+ * The string to rip from.
* @param range
- * A range within the source to restrict the copy from.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_partial_prepend_nulless_
- extern f_status_t fl_string_dynamic_partial_prepend_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_partial_prepend_nulless_
-
-/**
- * Prepend the source string onto the destination.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * @param source
- * The source string to prepend.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_prepend_
- extern f_status_t fl_string_dynamic_prepend(const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_prepend_
-
-/**
- * Prepend the source string onto the destination, but only if the string is not already at the beginning.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- *
- * @param source
- * The source string to prepend.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_prepend_assure_
- extern f_status_t fl_string_dynamic_prepend_assure(const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_prepend_assure_
-
-/**
- * Prepend the source string onto the destination, but only if the string is not already at the beginning.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- *
- * @param source
- * The source string to prepend.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_prepend_assure_nulless_
- extern f_status_t fl_string_dynamic_prepend_assure_nulless(const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_prepend_assure_nulless_
-
-/**
- * Prepend the source string onto the destination.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * @param source
- * The source string to prepend.
+ * A range within the buffer representing the string to rip.
* @param destination
- * The destination string the source is prepended onto.
+ * The new string, which will be allocated or reallocated as necessary.
*
* @return
* F_none on success.
* F_data_not_stop if range.start > range.stop.
* F_memory_not (with error bit) on out of memory.
* F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
*/
-#ifndef _di_fl_string_dynamic_prepend_nulless_
- extern f_status_t fl_string_dynamic_prepend_nulless(const f_string_static_t source, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_prepend_nulless_
+#ifndef _di_fl_string_dynamic_rip_nulless_
+ extern f_status_t fl_string_dynamic_rip_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
+#endif // _di_fl_string_dynamic_rip_nulless_
/**
- * Allocate a new string from the provided range in the buffer.
+ * Allocate a new string from the provided range in the string.
*
* Ignores leading and trailing whitespace.
* Ignores leading and trailing NULL characters.
- * As a result, resulting size may be smaller than requested range.
+ * As a result, resulting size may be smaller than requested length.
*
* @param source
- * The buffer to rip from.
- * @param range
- * A range within the buffer representing the string to rip.
+ * The string to rip from.
+ * @param length
+ * The length of source to append.
* @param destination
* The new string, which will be allocated or reallocated as necessary.
*
* @return
* F_none on success.
* F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
* F_memory_not (with error bit) on out of memory.
* F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
+ *
+ * Errors (with error bit) from: f_utf_is_whitespace().
+ *
+ * @see f_utf_is_whitespace()
*/
-#ifndef _di_fl_string_dynamic_rip_
- extern f_status_t fl_string_dynamic_rip(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_rip_
+#ifndef _di_fl_string_rip_
+ extern f_status_t fl_string_rip(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_fl_string_rip_
/**
- * Allocate a new string from the provided range in the buffer.
+ * Allocate a new string from the provided range in the string.
*
* Ignores leading and trailing whitespace.
* Ignores leading and trailing NULL characters.
- * As a result, resulting size may be smaller than requested range.
+ * As a result, resulting size may be smaller than requested length.
*
- * Skips over NULL characters from source when appending.
+ * Skips over NULL characters from source when ripping.
*
* @param source
* The string to rip from.
- * @param range
- * A range within the buffer representing the string to rip.
+ * @param length
+ * The length of source to append.
* @param destination
* The new string, which will be allocated or reallocated as necessary.
*
* @return
* F_none on success.
* F_data_not_eos if source length is 0.
- * F_data_not_stop if range.start > range.stop.
* F_memory_not (with error bit) on out of memory.
* F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_dynamic_rip_nulless_
- extern f_status_t fl_string_dynamic_rip_nulless(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_rip_nulless_
-
-/**
- * Resize the dynamic string to a larger size.
- *
- * This will resize making the string larger based on the given length.
- * If the given length is too large for the buffer, then attempt to set max buffer size (f_string_length_t_size).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param amount
- * A positive number representing how much to increase the size by.
- * @param string
- * The string to resize.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_dynamic_increase_
- extern f_status_t fl_string_dynamic_increase(f_string_dynamic_t *string);
-#endif // _di_fl_string_dynamic_increase_
-
-/**
- * Resize the dynamic string to a larger size.
*
- * This will resize making the string larger based on the given length.
- * If the given length is too large for the buffer, then attempt to set max buffer size (f_string_length_t_size).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param amount
- * A positive number representing how much to increase the size by.
- * @param string
- * The string to resize.
+ * Errors (with error bit) from: f_utf_is_whitespace().
*
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
+ * @see f_utf_is_whitespace()
*/
-#ifndef _di_fl_string_dynamic_increase_by_
- extern f_status_t fl_string_dynamic_increase_by(const f_string_length_t amount, f_string_dynamic_t *string);
-#endif // _di_fl_string_dynamic_increase_by_
+#ifndef _di_fl_string_rip_nulless_
+ extern f_status_t fl_string_rip_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
+#endif // _di_fl_string_rip_nulless_
/**
* Seek the buffer location forward until EOL is reached.
#endif // _di_fl_string_dynamic_seek_to_utf_character_
/**
- * Guarantee that an end of string (NULL) exists at the end of the string.
- *
- * This is intended to be used for anything requiring NULL terminated strings.
- * This will reallocate more space if necessary.
- *
- * If destination size is 0, then it will be reallocated and have the NULL assigned at index 0.
- *
- * @param destination
- * The new string, which will be allocated or reallocated as necessary.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if string is too large to fit into the buffer.
- */
-#ifndef _di_fl_string_dynamic_terminate_
- extern f_status_t fl_string_dynamic_terminate(f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_terminate_
-
-/**
- * Guarantee that an end of string (NULL) exists at the end of the string.
- *
- * This ensures that the terminating NULL not only exists but is not counted in destination.used.
- *
- * This is intended to be used for anything requiring NULL terminated strings whose used length cannot be counted.
- * This will reallocate more space if necessary.
- *
- * If destination size is 0, then it will be reallocated and have the NULL assigned at index 0.
- *
- * @param destination
- * The new string, which will be allocated or reallocated as necessary.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if string is too large to fit into the buffer.
- */
-#ifndef _di_fl_string_dynamic_terminate_after_
- extern f_status_t fl_string_dynamic_terminate_after(f_string_dynamic_t *destination);
-#endif // _di_fl_string_dynamic_terminate_after_
-
-/**
- * Resize the dynamic string array to a smaller size, by 1.
- *
- * This will shrink the size by size - 1.
- * This will not shrink the size to less than 0.
- *
- * @param strings
- * The string array to resize.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_dynamics_decrease_
- extern f_status_t fl_string_dynamics_decrease(f_string_dynamics_t *strings);
-#endif // _di_fl_string_dynamics_decrease_
-
-/**
- * Resize the dynamic string array to a smaller size.
- *
- * This will resize making the array smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
- *
- * @param amount
- * A positive number representing how much to decrease the size by.
- * @param strings
- * The string array to resize.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_dynamics_decrease_by_
- extern f_status_t fl_string_dynamics_decrease_by(const f_array_length_t amount, f_string_dynamics_t *strings);
-#endif // _di_fl_string_dynamics_decrease_by_
-
-/**
- * Delete the array of dynamic strings.
- *
- * @param string
- * The string to delete.
- *
- * @return
- * F_none on success.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_dynamics_delete_
- extern f_status_t fl_string_dynamics_delete(f_string_dynamics_t *strings);
-#endif // _di_fl_string_dynamics_delete_
-
-/**
- * Increase the size of the dynamic string array, but only if necessary.
- *
- * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param strings
- * The string array to resize.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_array_too_large (with error bit) if the new array length is too large.
- */
-#ifndef _di_fl_string_dynamics_increase_
- extern f_status_t fl_string_dynamics_increase(f_string_dynamics_t *strings);
-#endif // _di_fl_string_dynamics_increase_
-
-/**
- * Resize the dynamic string array to a larger size.
- *
- * This will resize making the string larger based on the given length.
- * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param amount
- * A positive number representing how much to increase the size by.
- * @param strings
- * The string array to resize.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_array_too_large (with error bit) if the new array length is too large.
- */
-#ifndef _di_fl_string_dynamics_increase_by_
- extern f_status_t fl_string_dynamics_increase_by(const f_array_length_t amount, f_string_dynamics_t *strings);
-#endif // _di_fl_string_dynamics_increase_by_
-
-/**
- * Resize the string maps array to a smaller size, by 1.
- *
- * This will shrink the size by size - 1.
- * This will not shrink the size to less than 0.
- *
- * @param maps
- * The string maps array to resize.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_maps_decrease_
- extern f_status_t fl_string_maps_decrease(f_string_maps_t *maps);
-#endif // _di_fl_string_maps_decrease_
-
-/**
- * Resize the string maps array to a smaller size.
- *
- * This will resize making the array smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
- *
- * @param amount
- * A positive number representing how much to decrease the size by.
- * @param maps
- * The string maps array to resize.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_maps_decrease_by_
- extern f_status_t fl_string_maps_decrease_by(const f_array_length_t amount, f_string_maps_t *maps);
-#endif // _di_fl_string_maps_decrease_by_
-
-/**
- * Delete the array of string maps.
- *
- * @param maps
- * The maps to delete.
- *
- * @return
- * F_none on success.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_maps_delete_
- extern f_status_t fl_string_maps_delete(f_string_maps_t *maps);
-#endif // _di_fl_string_maps_delete_
-
-/**
- * Increase the size of the string maps array, but only if necessary.
- *
- * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param maps
- * The string maps array to resize.
- *
- * @return
- * F_none on success.
- * F_array_too_large (with error bit) if the new array length is too large.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_fl_string_maps_increase_
- extern f_status_t fl_string_maps_increase(f_string_maps_t *maps);
-#endif // _di_fl_string_maps_increase_
-
-/**
- * Resize the string maps array to a larger size.
- *
- * This will resize making the string larger based on the given length.
- * If the given length is too large for the buffer, then attempt to set max buffer size (f_array_length_t_size).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param amount
- * A positive number representing how much to increase the size by.
- * @param maps
- * The string maps array to resize.
- *
- * @return
- * F_none on success.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_array_too_large (with error bit) if the new array length is too large.
- */
-#ifndef _di_fl_string_maps_increase_by_
- extern f_status_t fl_string_maps_increase_by(const f_array_length_t amount, f_string_maps_t *maps);
-#endif // _di_fl_string_maps_increase_by_
-
-/**
- * Append the source string onto the destination with the glue in between.
- *
- * If the destination string is empty, then no glue is appended.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_mash_
- extern f_status_t fl_string_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_mash_
-
-/**
- * Append the source string onto the destination with the glue in between.
- *
- * If the destination string is empty, then no glue is appended.
- *
- * Skips over NULL characters from glue and source when appending.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_mash_nulless_
- extern f_status_t fl_string_mash_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_mash_nulless_
-
-/**
- * Prepend the source string onto the destination with the glue in between.
- *
- * If the destination string is empty, then no glue is appended.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_mish_
- extern f_status_t fl_string_mish(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_mish_
-
-/**
- * Prepend the source string onto the destination with the glue in between.
- *
- * If the destination string is empty, then no glue is appended.
- *
- * Skips over NULL characters from glue and source when appending.
- *
- * @param glue
- * A string to append between the source and destination, such as a space: ' '.
- * @param glue_length
- * The number of bytes the glue takes up.
- * @param source
- * The source string to append.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source and glue are appended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_mish_nulless_
- extern f_status_t fl_string_mish_nulless(const f_string_t glue, const f_string_length_t glue_length, const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_mish_nulless_
-
-/**
- * Prepend the source string onto the destination.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * @param source
- * The source string to prepend.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_prepend_
- extern f_status_t fl_string_prepend(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_prepend_
-
-/**
- * Prepend the source string onto the destination, but only if the string is not already at the beginning.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- *
- * @param source
- * The source string to prepend.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_prepend_assure_
- extern f_status_t fl_string_prepend_assure(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_prepend_assure_
-
-/**
- * Prepend the source string onto the destination, but only if the string is not already at the beginning.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- * Skips over NULL characters from source when prepending.
- *
- * @param source
- * The source string to prepend.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_prepend_assure_nulless_
- extern f_status_t fl_string_prepend_assure_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_prepend_assure_nulless_
-
-/**
- * Prepend the source string onto the destination, but only if the string is not already at the beginning.
- *
- * Prepend operations require memory move operations and are therefore likely more expensive than append operations.
- *
- * This ignores NULL characters when comparing both the source and the destination.
- * Skips over NULL characters from source when prepending.
- *
- * @param source
- * The source string to prepend.
- * @param length
- * The length of source to append.
- * @param destination
- * The destination string the source is prepended onto.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- * F_string_too_large (with error bit) if the combined string is too large.
- */
-#ifndef _di_fl_string_prepend_nulless_
- extern f_status_t fl_string_prepend_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_prepend_nulless_
-
-/**
- * Allocate a new string from the provided range in the string.
- *
- * Ignores leading and trailing whitespace.
- * Ignores leading and trailing NULL characters.
- * As a result, resulting size may be smaller than requested length.
- *
- * @param source
- * The string to rip from.
- * @param length
- * The length of source to append.
- * @param destination
- * The new string, which will be allocated or reallocated as necessary.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- *
- * Errors (with error bit) from: f_utf_is_whitespace().
- *
- * @see f_utf_is_whitespace()
- */
-#ifndef _di_fl_string_rip_
- extern f_status_t fl_string_rip(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_rip_
-
-/**
- * Allocate a new string from the provided range in the string.
- *
- * Ignores leading and trailing whitespace.
- * Ignores leading and trailing NULL characters.
- * As a result, resulting size may be smaller than requested length.
- *
- * Skips over NULL characters from source when ripping.
- *
- * @param source
- * The string to rip from.
- * @param length
- * The length of source to append.
- * @param destination
- * The new string, which will be allocated or reallocated as necessary.
- *
- * @return
- * F_none on success.
- * F_data_not_eos if source length is 0.
- * F_memory_not (with error bit) on out of memory.
- * F_parameter (with error bit) if a parameter is invalid.
- *
- * Errors (with error bit) from: f_utf_is_whitespace().
- *
- * @see f_utf_is_whitespace()
- */
-#ifndef _di_fl_string_rip_nulless_
- extern f_status_t fl_string_rip_nulless(const f_string_t source, const f_string_length_t length, f_string_dynamic_t *destination);
-#endif // _di_fl_string_rip_nulless_
-
-/**
* Seek the string location forward until the character (1-byte wide) or EOL is reached.
*
* @param string
}
#endif // !defined(_di_fl_utf_string_append_nulless_) || !defined(_di_fl_utf_string_dynamic_append_nulless_) || !defined(_di_fl_utf_string_mash_nulless_) || !defined(_di_fl_utf_string_dynamic_mash_nulless_)
-#if !defined(_di_fl_utf_string_compare_) || !defined(_di_fl_utf_string_dynamic_compare_) || !defined(_di_fl_utf_string_dynamic_partial_compare_)
- f_status_t private_fl_utf_string_compare(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t offset1, const f_utf_string_length_t offset2, const f_utf_string_length_t stop1, const f_utf_string_length_t stop2) {
+#if !defined(_di_fl_utfl_string_compare_) || !defined(_di_fl_utfl_string_dynamic_compare_) || !defined(_di_fl_utfl_string_dynamic_partial_compare_)
+ f_status_t private_fl_utfl_string_compare(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t offset1, const f_utf_string_length_t offset2, const f_utf_string_length_t stop1, const f_utf_string_length_t stop2) {
f_utf_string_length_t i1 = offset1;
f_utf_string_length_t i2 = offset2;
return F_equal_to;
}
-#endif // !defined(_di_fl_utf_string_compare_) || !defined(_di_fl_utf_string_dynamic_compare_) || !defined(_di_fl_utf_string_dynamic_partial_compare_)
+#endif // !defined(_di_fl_utfl_string_compare_) || !defined(_di_fl_utfl_string_dynamic_compare_) || !defined(_di_fl_utfl_string_dynamic_partial_compare_)
-#if !defined(_di_fl_utf_string_compare_trim_) || !defined(_di_fl_utf_string_dynamic_compare_trim_) || !defined(_di_fl_utf_string_dynamic_partial_compare_trim_)
- f_status_t private_fl_utf_string_compare_trim(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t offset1, const f_utf_string_length_t offset2, const f_utf_string_length_t stop1, const f_utf_string_length_t stop2) {
+#if !defined(_di_fl_utfl_string_compare_trim_) || !defined(_di_fl_utfl_string_dynamic_compare_trim_) || !defined(_di_fl_utfl_string_dynamic_partial_compare_trim_)
+ f_status_t private_fl_utfl_string_compare_trim(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t offset1, const f_utf_string_length_t offset2, const f_utf_string_length_t stop1, const f_utf_string_length_t stop2) {
f_utf_string_length_t i1 = offset1;
f_utf_string_length_t i2 = offset2;
return F_equal_to;
}
-#endif // !defined(_di_fl_utf_string_compare_trim_) || !defined(_di_fl_utf_string_dynamic_compare_trim_) || !defined(_di_fl_utf_string_dynamic_partial_compare_trim_)
+#endif // !defined(_di_fl_utfl_string_compare_trim_) || !defined(_di_fl_utfl_string_dynamic_compare_trim_) || !defined(_di_fl_utfl_string_dynamic_partial_compare_trim_)
#if !defined(_di_fl_utf_string_prepend_) || !defined(_di_fl_utf_string_dynamic_prepend_)
f_status_t private_fl_utf_string_prepend(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination) {
}
#endif // !defined(_di_fl_utf_string_prepend_nulless_) || !defined(_di_fl_utf_string_dynamic_prepend_nulless_)
-#if !defined(_di_fl_utf_string_rip_) || !defined(_di_fl_utf_string_dynamic_rip_) || !defined(_di_fl_utf_string_rip_nulless_) || !defined(_di_fl_utf_string_dynamic_rip_nulless_)
- f_status_t private_fl_utf_string_rip_find_range(const f_utf_string_t source, f_utf_string_length_t *start, f_utf_string_length_t *stop) {
+#if !defined(_di_fl_utfl_string_rip_) || !defined(_di_fl_utfl_string_dynamic_rip_) || !defined(_di_fl_utfl_string_rip_nulless_) || !defined(_di_fl_utfl_string_dynamic_rip_nulless_)
+ f_status_t private_fl_utfl_string_rip_find_range(const f_utf_string_t source, f_utf_string_length_t *start, f_utf_string_length_t *stop) {
f_status_t status = F_none;
return F_none;
}
-#endif // !defined(_di_fl_utf_string_rip_) || !defined(_di_fl_utf_string_dynamic_rip_) || !defined(_di_fl_utf_string_rip_nulless_) || !defined(_di_fl_utf_string_dynamic_rip_nulless_)
+#endif // !defined(_di_fl_utfl_string_rip_) || !defined(_di_fl_utfl_string_dynamic_rip_) || !defined(_di_fl_utfl_string_rip_nulless_) || !defined(_di_fl_utfl_string_dynamic_rip_nulless_)
#ifdef __cplusplus
} // extern "C"
#endif // !defined(_di_fl_utf_string_append_nulless_) || !defined(_di_fl_utf_string_dynamic_append_nulless_) || !defined(_di_fl_utf_string_mash_nulless_) || !defined(_di_fl_utf_string_dynamic_mash_nulless_)
/**
- * Private implementation of fl_utf_string_compare().
+ * Private implementation of fl_utfl_string_compare().
*
* Intended to be shared to each of the different implementation variations.
*
* F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
*
- * @see fl_utf_string_compare()
- * @see fl_utf_string_dynamic_compare()
- * @see fl_utf_string_dynamic_partial_compare()
+ * @see fl_utfl_string_compare()
+ * @see fl_utfl_string_dynamic_compare()
+ * @see fl_utfl_string_dynamic_partial_compare()
*/
-#if !defined(_di_fl_utf_string_compare_) || !defined(_di_fl_utf_string_dynamic_compare_) || !defined(_di_fl_utf_string_dynamic_partial_compare_)
- extern f_status_t private_fl_utf_string_compare(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t offset1, const f_utf_string_length_t offset2, const f_utf_string_length_t stop1, const f_utf_string_length_t stop2) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_utf_string_compare_) || !defined(_di_fl_utf_string_dynamic_compare_) || !defined(_di_fl_utf_string_dynamic_partial_compare_)
+#if !defined(_di_fl_utfl_string_compare_) || !defined(_di_fl_utfl_string_dynamic_compare_) || !defined(_di_fl_utfl_string_dynamic_partial_compare_)
+ extern f_status_t private_fl_utfl_string_compare(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t offset1, const f_utf_string_length_t offset2, const f_utf_string_length_t stop1, const f_utf_string_length_t stop2) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_fl_utfl_string_compare_) || !defined(_di_fl_utfl_string_dynamic_compare_) || !defined(_di_fl_utfl_string_dynamic_partial_compare_)
/**
- * Private implementation of fl_utf_string_compare_trim().
+ * Private implementation of fl_utfl_string_compare_trim().
*
* Intended to be shared to each of the different implementation variations.
*
* F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
*
- * @see fl_utf_string_compare_trim()
- * @see fl_utf_string_dynamic_compare_trim()
- * @see fl_utf_string_dynamic_partial_compare_trim()
+ * @see fl_utfl_string_compare_trim()
+ * @see fl_utfl_string_dynamic_compare_trim()
+ * @see fl_utfl_string_dynamic_partial_compare_trim()
*/
-#if !defined(_di_fl_utf_string_compare_trim_) || !defined(_di_fl_utf_string_dynamic_compare_trim_) || !defined(_di_fl_utf_string_dynamic_partial_compare_trim_)
- extern f_status_t private_fl_utf_string_compare_trim(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t offset1, const f_utf_string_length_t offset2, const f_utf_string_length_t stop1, const f_utf_string_length_t stop2) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_utf_string_compare_trim_) || !defined(_di_fl_utf_string_dynamic_compare_trim_) || !defined(_di_fl_utf_string_dynamic_partial_compare_trim_)
+#if !defined(_di_fl_utfl_string_compare_trim_) || !defined(_di_fl_utfl_string_dynamic_compare_trim_) || !defined(_di_fl_utfl_string_dynamic_partial_compare_trim_)
+ extern f_status_t private_fl_utfl_string_compare_trim(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t offset1, const f_utf_string_length_t offset2, const f_utf_string_length_t stop1, const f_utf_string_length_t stop2) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_fl_utfl_string_compare_trim_) || !defined(_di_fl_utfl_string_dynamic_compare_trim_) || !defined(_di_fl_utfl_string_dynamic_partial_compare_trim_)
/**
* Private implementation of fl_utf_string_prepend().
#endif // !defined(_di_fl_utf_string_prepend_nulless_) || !defined(_di_fl_utf_string_dynamic_prepend_nulless_) || !defined(_di_fl_utf_string_append_mish_) || !defined(_di_fl_utf_string_dynamic_mish_)
/**
- * Private implementation of fl_utf_string_rip(), but only the part for finding the start/stop range.
+ * Private implementation of fl_utfl_string_rip(), but only the part for finding the start/stop range.
*
* Intended to be shared to each of the different implementation variations.
*
* F_memory_not (with error bit) on out of memory.
* F_parameter (with error bit) if a parameter is invalid.
*
- * @see fl_utf_string_dynamic_rip()
- * @see fl_utf_string_rip()
+ * @see fl_utfl_string_dynamic_rip()
+ * @see fl_utfl_string_rip()
*/
-#if !defined(_di_fl_utf_string_rip_) || !defined(_di_fl_utf_string_dynamic_rip_) || !defined(_di_fl_utf_string_rip_nulless_) || !defined(_di_fl_utf_string_dynamic_rip_nulless_)
- extern f_status_t private_fl_utf_string_rip_find_range(const f_utf_string_t source, f_utf_string_length_t *start, f_utf_string_length_t *stop) f_gcc_attribute_visibility_internal;
-#endif // !defined(_di_fl_utf_string_rip_) || !defined(_di_fl_utf_string_dynamic_rip_) || !defined(_di_fl_utf_string_rip_nulless_) || !defined(_di_fl_utf_string_dynamic_rip_nulless_)
+#if !defined(_di_fl_utfl_string_rip_) || !defined(_di_fl_utfl_string_dynamic_rip_) || !defined(_di_fl_utfl_string_rip_nulless_) || !defined(_di_fl_utfl_string_dynamic_rip_nulless_)
+ extern f_status_t private_fl_utfl_string_rip_find_range(const f_utf_string_t source, f_utf_string_length_t *start, f_utf_string_length_t *stop) f_gcc_attribute_visibility_internal;
+#endif // !defined(_di_fl_utfl_string_rip_) || !defined(_di_fl_utfl_string_dynamic_rip_) || !defined(_di_fl_utfl_string_rip_nulless_) || !defined(_di_fl_utfl_string_dynamic_rip_nulless_)
#ifdef __cplusplus
} // extern "C"
}
#endif // _di_fl_utf_string_append_nulless_
-#ifndef _di_fl_utf_string_compare_
- f_status_t fl_utf_string_compare(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t length1, const f_utf_string_length_t length2) {
- return private_fl_utf_string_compare(string1, string2, 0, 0, length1, length2);
+#ifndef _di_fl_utfl_string_compare_
+ f_status_t fl_utfl_string_compare(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t length1, const f_utf_string_length_t length2) {
+ return private_fl_utfl_string_compare(string1, string2, 0, 0, length1, length2);
}
-#endif // _di_fl_utf_string_compare_
+#endif // _di_fl_utfl_string_compare_
-#ifndef _di_fl_utf_string_compare_trim_
- f_status_t fl_utf_string_compare_trim(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t length1, const f_utf_string_length_t length2) {
- return private_fl_utf_string_compare_trim(string1, string2, 0, 0, length1, length2);
+#ifndef _di_fl_utfl_string_compare_trim_
+ f_status_t fl_utfl_string_compare_trim(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t length1, const f_utf_string_length_t length2) {
+ return private_fl_utfl_string_compare_trim(string1, string2, 0, 0, length1, length2);
}
-#endif // _di_fl_utf_string_compare_trim_
+#endif // _di_fl_utfl_string_compare_trim_
#ifndef _di_fl_utf_string_dynamic_append_
f_status_t fl_utf_string_dynamic_append(const f_utf_string_static_t source, f_utf_string_dynamic_t *destination) {
}
#endif // _di_fl_utf_string_dynamic_append_nulless_
-#ifndef _di_fl_utf_string_dynamic_compare_
- f_status_t fl_utf_string_dynamic_compare(const f_utf_string_static_t string1, const f_utf_string_static_t string2) {
- return private_fl_utf_string_compare(string1.string, string2.string, 0, 0, string1.used, string2.used);
+#ifndef _di_fl_utfl_string_dynamic_compare_
+ f_status_t fl_utfl_string_dynamic_compare(const f_utf_string_static_t string1, const f_utf_string_static_t string2) {
+ return private_fl_utfl_string_compare(string1.string, string2.string, 0, 0, string1.used, string2.used);
}
-#endif // _di_fl_utf_string_dynamic_compare_
+#endif // _di_fl_utfl_string_dynamic_compare_
-#ifndef _di_f_utf_string_dynamic_compare_trim_
- f_status_t f_utf_string_dynamic_compare_trim(const f_utf_string_static_t string1, const f_utf_string_static_t string2) {
- return private_fl_utf_string_compare_trim(string1.string, string2.string, 0, 0, string1.used, string2.used);
+#ifndef _di_f_utfl_string_dynamic_compare_trim_
+ f_status_t f_utfl_string_dynamic_compare_trim(const f_utf_string_static_t string1, const f_utf_string_static_t string2) {
+ return private_fl_utfl_string_compare_trim(string1.string, string2.string, 0, 0, string1.used, string2.used);
}
-#endif // _di_f_utf_string_dynamic_compare_trim_
+#endif // _di_f_utfl_string_dynamic_compare_trim_
#ifndef _di_fl_utf_string_dynamic_mash_
f_status_t fl_utf_string_dynamic_mash(const f_utf_string_t glue, const f_utf_string_length_t glue_length, const f_utf_string_static_t source, f_utf_string_dynamic_t *destination) {
}
#endif // _di_fl_utf_string_dynamic_partial_append_nulless_
-#ifndef _di_fl_utf_string_dynamic_partial_compare_
- f_status_t fl_utf_string_dynamic_partial_compare(const f_utf_string_static_t string1, const f_utf_string_static_t string2, const f_utf_string_range_t range1, const f_utf_string_range_t range2) {
+#ifndef _di_fl_utfl_string_dynamic_partial_compare_
+ f_status_t fl_utfl_string_dynamic_partial_compare(const f_utf_string_static_t string1, const f_utf_string_static_t string2, const f_utf_string_range_t range1, const f_utf_string_range_t range2) {
#ifndef _di_level_1_parameter_checking_
if (string1.used <= range1.stop) return F_status_set_error(F_parameter);
if (string2.used <= range2.stop) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
- return private_fl_utf_string_compare(string1.string, string2.string, range1.start, range2.start, range1.stop + 1, range2.stop + 1);
+ return private_fl_utfl_string_compare(string1.string, string2.string, range1.start, range2.start, range1.stop + 1, range2.stop + 1);
}
-#endif // _di_fl_utf_string_dynamic_partial_compare_
+#endif // _di_fl_utfl_string_dynamic_partial_compare_
-#ifndef _di_fl_utf_string_dynamic_partial_compare_trim_
- f_status_t fl_utf_string_dynamic_partial_comparetrim(const f_utf_string_static_t string1, const f_utf_string_static_t string2, const f_utf_string_range_t range1, const f_utf_string_range_t range2) {
+#ifndef _di_fl_utfl_string_dynamic_partial_compare_trim_
+ f_status_t fl_utfl_string_dynamic_partial_comparetrim(const f_utf_string_static_t string1, const f_utf_string_static_t string2, const f_utf_string_range_t range1, const f_utf_string_range_t range2) {
#ifndef _di_level_1_parameter_checking_
if (string1.used <= range1.stop) return F_status_set_error(F_parameter);
if (string2.used <= range2.stop) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
- return private_fl_utf_string_compare_trim(string1.string, string2.string, range1.start, range2.start, range1.stop + 1, range2.stop + 1);
+ return private_fl_utfl_string_compare_trim(string1.string, string2.string, range1.start, range2.start, range1.stop + 1, range2.stop + 1);
}
-#endif // _di_fl_utf_string_dynamic_partial_compare_trim_
+#endif // _di_fl_utfl_string_dynamic_partial_compare_trim_
#ifndef _di_fl_utf_string_dynamic_partial_mash_
f_status_t fl_utf_string_dynamic_partial_mash(const f_utf_string_t glue, const f_utf_string_length_t glue_length, const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination) {
}
#endif // _di_fl_utf_string_dynamic_prepend_nulless_
-#ifndef _di_fl_utf_string_dynamic_rip_
- f_status_t fl_utf_string_dynamic_rip(const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination) {
+#ifndef _di_fl_utfl_string_dynamic_rip_
+ f_status_t fl_utfl_string_dynamic_rip(const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination) {
#ifndef _di_level_1_parameter_checking_
if (source.used <= range.start) return F_status_set_error(F_parameter);
if (source.used <= range.stop) return F_status_set_error(F_parameter);
return private_fl_utf_string_append(source.string + range.start, (range.stop - range.start) + 1, destination);
}
-#endif // _di_fl_utf_string_dynamic_rip_
+#endif // _di_fl_utfl_string_dynamic_rip_
-#ifndef _di_fl_utf_string_dynamic_rip_nulless_
- f_status_t fl_utf_string_dynamic_rip_nulless(const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination) {
+#ifndef _di_fl_utfl_string_dynamic_rip_nulless_
+ f_status_t fl_utfl_string_dynamic_rip_nulless(const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination) {
#ifndef _di_level_1_parameter_checking_
if (source.used <= range.start) return F_status_set_error(F_parameter);
if (source.used <= range.stop) return F_status_set_error(F_parameter);
return private_fl_utf_string_append_nulless(source.string + range.start, (range.stop - range.start) + 1, destination);
}
-#endif // _di_fl_utf_string_dynamic_rip_nulless_
+#endif // _di_fl_utfl_string_dynamic_rip_nulless_
-#ifndef _di_fl_utf_string_dynamic_seek_line_to_
- f_status_t fl_utf_string_dynamic_seek_line_to(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this) {
+#ifndef _di_fl_utfl_string_dynamic_seek_line_to_
+ f_status_t fl_utfl_string_dynamic_seek_line_to(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
if (buffer.used <= range->start) return F_status_set_error(F_parameter);
return F_none;
}
-#endif // _di_fl_utf_string_dynamic_seek_line_to_
+#endif // _di_fl_utfl_string_dynamic_seek_line_to_
-#ifndef _di_fl_utf_string_dynamic_seek_line_to_char_
- f_status_t fl_utf_string_dynamic_seek_line_to_char(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const int8_t seek_to_this) {
+#ifndef _di_fl_utfl_string_dynamic_seek_line_to_char_
+ f_status_t fl_utfl_string_dynamic_seek_line_to_char(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const int8_t seek_to_this) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
if (buffer.used <= range->start) return F_status_set_error(F_parameter);
return F_none;
}
-#endif // _di_fl_utf_string_dynamic_seek_line_to_character_
+#endif // _di_fl_utfl_string_dynamic_seek_line_to_character_
-#ifndef _di_fl_utf_string_dynamic_seek_line_until_graph_
- f_status_t fl_utf_string_dynamic_seek_line_until_graph(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t placeholder) {
+#ifndef _di_fl_utfl_string_dynamic_seek_line_until_graph_
+ f_status_t fl_utfl_string_dynamic_seek_line_until_graph(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t placeholder) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
if (buffer.used <= range->start) return F_status_set_error(F_parameter);
return F_none;
}
-#endif // _di_fl_utf_string_dynamic_seek_line_until_graph_
+#endif // _di_fl_utfl_string_dynamic_seek_line_until_graph_
-#ifndef _di_fl_utf_string_dynamic_seek_line_until_non_graph_
- f_status_t fl_utf_string_dynamic_seek_line_until_non_graph(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t placeholder) {
+#ifndef _di_fl_utfl_string_dynamic_seek_line_until_non_graph_
+ f_status_t fl_utfl_string_dynamic_seek_line_until_non_graph(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t placeholder) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
if (buffer.used <= range->start) return F_status_set_error(F_parameter);
return F_none;
}
-#endif // _di_fl_utf_string_dynamic_seek_line_until_non_graph_
+#endif // _di_fl_utfl_string_dynamic_seek_line_until_non_graph_
-#ifndef _di_fl_utf_string_dynamic_seek_to_
- f_status_t fl_utf_string_dynamic_seek_to(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this) {
+#ifndef _di_fl_utfl_string_dynamic_seek_to_
+ f_status_t fl_utfl_string_dynamic_seek_to(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
if (buffer.used <= range->start) return F_status_set_error(F_parameter);
return F_none;
}
-#endif // _di_fl_utf_string_dynamic_seek_to_
+#endif // _di_fl_utfl_string_dynamic_seek_to_
-#ifndef _di_fl_utf_string_dynamic_seek_to_char_
- f_status_t fl_utf_string_dynamic_seek_to_char(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const int8_t seek_to_this) {
+#ifndef _di_fl_utfl_string_dynamic_seek_to_char_
+ f_status_t fl_utfl_string_dynamic_seek_to_char(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const int8_t seek_to_this) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
if (buffer.used <= range->start) return F_status_set_error(F_parameter);
return F_none;
}
-#endif // _di_fl_utf_string_dynamic_seek_to_char_
+#endif // _di_fl_utfl_string_dynamic_seek_to_char_
#ifndef _di_fl_utf_string_dynamic_terminate_
f_status_t fl_utf_string_dynamic_terminate(f_utf_string_dynamic_t *destination) {
}
#endif // _di_fl_utf_string_prepend_nulless_
-#ifndef _di_fl_utf_string_rip_
- f_status_t fl_utf_string_rip(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination) {
+#ifndef _di_fl_utfl_string_rip_
+ f_status_t fl_utfl_string_rip(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination) {
#ifndef _di_level_1_parameter_checking_
if (!destination) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
f_utf_string_length_t begin = 0;
f_utf_string_length_t end = length - 1;
- f_status_t status = private_fl_utf_string_rip_find_range(source, &begin, &end);
+ f_status_t status = private_fl_utfl_string_rip_find_range(source, &begin, &end);
if (F_status_is_error(status)) return status;
if (status == F_data_not) return status;
return private_fl_utf_string_append(source + begin, (end - begin) + 1, destination);
}
-#endif // _di_fl_utf_string_rip_
+#endif // _di_fl_utfl_string_rip_
-#ifndef _di_fl_utf_string_rip_nulless_
- f_status_t fl_utf_string_rip_nulless(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination) {
+#ifndef _di_fl_utfl_string_rip_nulless_
+ f_status_t fl_utfl_string_rip_nulless(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination) {
#ifndef _di_level_1_parameter_checking_
if (!destination) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
f_utf_string_length_t begin = 0;
f_utf_string_length_t end = length - 1;
- f_status_t status = private_fl_utf_string_rip_find_range(source, &begin, &end);
+ f_status_t status = private_fl_utfl_string_rip_find_range(source, &begin, &end);
if (F_status_is_error(status)) return status;
if (status == F_data_not) return status;
return private_fl_utf_string_append_nulless(source + begin, (end - begin) + 1, destination);
}
-#endif // _di_fl_utf_string_rip_nulless_
+#endif // _di_fl_utfl_string_rip_nulless_
-#ifndef _di_fl_utf_string_seek_line_to_
- f_status_t fl_utf_string_seek_line_to(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t seek_to_this) {
+#ifndef _di_fl_utfl_string_seek_line_to_
+ f_status_t fl_utfl_string_seek_line_to(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t seek_to_this) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
return F_none;
}
-#endif // _di_fl_utf_string_seek_line_to_
+#endif // _di_fl_utfl_string_seek_line_to_
-#ifndef _di_fl_utf_string_seek_line_to_char_
- f_status_t fl_utf_string_seek_line_to_char(const f_utf_string_t string, f_utf_string_range_t *range, const int8_t seek_to_this) {
+#ifndef _di_fl_utfl_string_seek_line_to_char_
+ f_status_t fl_utfl_string_seek_line_to_char(const f_utf_string_t string, f_utf_string_range_t *range, const int8_t seek_to_this) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
return F_none_stop;
}
-#endif // _di_fl_utf_string_seek_line_to_char_
+#endif // _di_fl_utfl_string_seek_line_to_char_
-#ifndef _di_fl_utf_string_seek_line_until_graph_
- f_status_t fl_utf_string_seek_line_until_graph(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t placeholder) {
+#ifndef _di_fl_utfl_string_seek_line_until_graph_
+ f_status_t fl_utfl_string_seek_line_until_graph(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t placeholder) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
return F_none;
}
-#endif // _di_fl_utf_string_seek_line_until_graph_
+#endif // _di_fl_utfl_string_seek_line_until_graph_
-#ifndef _di_fl_utf_string_seek_line_until_non_graph_
- f_status_t fl_utf_string_seek_line_until_non_graph(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t placeholder) {
+#ifndef _di_fl_utfl_string_seek_line_until_non_graph_
+ f_status_t fl_utfl_string_seek_line_until_non_graph(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t placeholder) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
return F_none;
}
-#endif // _di_fl_utf_string_seek_line_until_non_graph_
+#endif // _di_fl_utfl_string_seek_line_until_non_graph_
-#ifndef _di_fl_utf_string_seek_to_
- f_status_t fl_utf_string_seek_to(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t seek_to_this) {
+#ifndef _di_fl_utfl_string_seek_to_
+ f_status_t fl_utfl_string_seek_to(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t seek_to_this) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
return F_none;
}
-#endif // _di_fl_utf_string_seek_to_
+#endif // _di_fl_utfl_string_seek_to_
-#ifndef _di_fl_utf_string_seek_to_char_
- f_status_t fl_utf_string_seek_to_char(const f_utf_string_t string, f_utf_string_range_t *range, const int8_t seek_to_this) {
+#ifndef _di_fl_utfl_string_seek_to_char_
+ f_status_t fl_utfl_string_seek_to_char(const f_utf_string_t string, f_utf_string_range_t *range, const int8_t seek_to_this) {
#ifndef _di_level_1_parameter_checking_
if (!range) return F_status_set_error(F_parameter);
#endif // _di_level_1_parameter_checking_
return F_none_stop;
}
-#endif // _di_fl_utf_string_seek_to_utf_character_
+#endif // _di_fl_utfl_string_seek_to_utf_character_
#ifdef __cplusplus
} // extern "C"
* F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
*/
-#ifndef _di_fl_utf_string_compare_
- extern f_status_t fl_utf_string_compare(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t length1, const f_utf_string_length_t length2);
-#endif // _di_fl_utf_string_compare_
+#ifndef _di_fl_utfl_string_compare_
+ extern f_status_t fl_utfl_string_compare(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t length1, const f_utf_string_length_t length2);
+#endif // _di_fl_utfl_string_compare_
/**
* Compare two UTF-8 strings, similar to strncmp().
*
* @see f_utf_character_is_whitespace()
*/
-#ifndef _di_fl_utf_string_compare_trim_
- extern f_status_t fl_utf_string_compare_trim(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t length1, const f_utf_string_length_t length2);
-#endif // _di_fl_utf_string_compare_trim_
+#ifndef _di_fl_utfl_string_compare_trim_
+ extern f_status_t fl_utfl_string_compare_trim(const f_utf_string_t string1, const f_utf_string_t string2, const f_utf_string_length_t length1, const f_utf_string_length_t length2);
+#endif // _di_fl_utfl_string_compare_trim_
/**
* Append the UTF-8 source string onto the destination.
* F_parameter (with error bit) if a parameter is invalid.
* F_utf (with error bit) if a character in the string is an invalid UTF-8 character.
*/
-#ifndef _di_fl_utf_string_dynamic_compare_
- extern f_status_t fl_utf_string_dynamic_compare(const f_utf_string_static_t string1, const f_utf_string_static_t string2);
-#endif // _di_fl_utf_string_dynamic_compare_
+#ifndef _di_fl_utfl_string_dynamic_compare_
+ extern f_status_t fl_utfl_string_dynamic_compare(const f_utf_string_static_t string1, const f_utf_string_static_t string2);
+#endif // _di_fl_utfl_string_dynamic_compare_
/**
* Compare two UTF-8 strings, similar to strncmp().
*
* @see f_utf_character_is_whitespace()
*/
-#ifndef _di_f_utf_string_dynamic_compare_trim_
- extern f_status_t f_utf_string_dynamic_compare_trim(const f_utf_string_static_t string1, const f_utf_string_static_t string2);
-#endif // _di_f_utf_string_dynamic_compare_trim_
+#ifndef _di_f_utfl_string_dynamic_compare_trim_
+ extern f_status_t f_utfl_string_dynamic_compare_trim(const f_utf_string_static_t string1, const f_utf_string_static_t string2);
+#endif // _di_f_utfl_string_dynamic_compare_trim_
/**
* Append the UTF-8 source string onto the destination with the glue in between.
* F_equal_to_not when both strings do not equal.
* F_parameter (with error bit) if a parameter is invalid.
*/
-#ifndef _di_fl_utf_string_dynamic_partial_compare_
- extern f_status_t fl_utf_string_dynamic_partial_compare(const f_utf_string_static_t string1, const f_utf_string_static_t string2, const f_utf_string_range_t range1, const f_utf_string_range_t range2);
-#endif // _di_fl_utf_string_dynamic_partial_compare_
+#ifndef _di_fl_utfl_string_dynamic_partial_compare_
+ extern f_status_t fl_utfl_string_dynamic_partial_compare(const f_utf_string_static_t string1, const f_utf_string_static_t string2, const f_utf_string_range_t range1, const f_utf_string_range_t range2);
+#endif // _di_fl_utfl_string_dynamic_partial_compare_
/**
* Compare two UTF-8 strings, similar to strncmp(), but restricted to the given ranges.
*
* @see f_utf_character_is_whitespace()
*/
-#ifndef _di_fl_utf_string_dynamic_partial_compare_trim_
- extern f_status_t fl_utf_string_dynamic_partial_compare_trim(const f_utf_string_static_t string1, const f_utf_string_static_t string2, const f_utf_string_range_t range1, const f_utf_string_range_t range2);
-#endif // _di_fl_utf_string_dynamic_partial_compare_trim_
+#ifndef _di_fl_utfl_string_dynamic_partial_compare_trim_
+ extern f_status_t fl_utfl_string_dynamic_partial_compare_trim(const f_utf_string_static_t string1, const f_utf_string_static_t string2, const f_utf_string_range_t range1, const f_utf_string_range_t range2);
+#endif // _di_fl_utfl_string_dynamic_partial_compare_trim_
/**
* Append the UTF-8 source string onto the destination with the glue in between, but restricted to the given range.
* F_parameter (with error bit) if a parameter is invalid.
* F_string_too_large (with error bit) if the combined string is too large.
*/
-#ifndef _di_fl_utf_string_dynamic_rip_
- extern f_status_t fl_utf_string_dynamic_rip(const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination);
-#endif // _di_fl_utf_string_dynamic_rip_
+#ifndef _di_fl_utfl_string_dynamic_rip_
+ extern f_status_t fl_utfl_string_dynamic_rip(const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination);
+#endif // _di_fl_utfl_string_dynamic_rip_
/**
* Allocate a new UTF-8 string from the provided range in the buffer.
* F_memory_not (with error bit) on out of memory.
* F_parameter (with error bit) if a parameter is invalid.
*/
-#ifndef _di_fl_utf_string_dynamic_rip_nulless_
- extern f_status_t fl_utf_string_dynamic_rip_nulless(const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination);
-#endif // _di_fl_utf_string_dynamic_rip_nulless_
+#ifndef _di_fl_utfl_string_dynamic_rip_nulless_
+ extern f_status_t fl_utfl_string_dynamic_rip_nulless(const f_utf_string_static_t source, const f_utf_string_range_t range, f_utf_string_dynamic_t *destination);
+#endif // _di_fl_utfl_string_dynamic_rip_nulless_
/**
* Seek the buffer location forward until the UTF-8 character or EOL is reached.
* F_parameter (with error bit) if a parameter is invalid.
* F_utf (with error bit) if a character in the buffer is an invalid UTF-8 character.
*/
-#ifndef _di_fl_utf_string_dynamic_seek_line_to_
- extern f_status_t fl_utf_string_dynamic_seek_line_to(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
-#endif // _di_fl_utf_string_dynamic_seek_line_to_
+#ifndef _di_fl_utfl_string_dynamic_seek_line_to_
+ extern f_status_t fl_utfl_string_dynamic_seek_line_to(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
+#endif // _di_fl_utfl_string_dynamic_seek_line_to_
/**
* Seek the buffer location forward until the (1-byte wide) character or EOL is reached.
* F_parameter (with error bit) if a parameter is invalid.
* F_utf (with error bit) if a character in the buffer is an invalid UTF-8 character.
*/
-#ifndef _di_fl_utf_string_seek_line_to_char_
- extern f_status_t fl_utf_string_dynamic_seek_line_to_char(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const int8_t seek_to_this);
-#endif // _di_fl_utf_string_seek_line_to_char_
+#ifndef _di_fl_utfl_string_seek_line_to_char_
+ extern f_status_t fl_utfl_string_dynamic_seek_line_to_char(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const int8_t seek_to_this);
+#endif // _di_fl_utfl_string_seek_line_to_char_
/**
* Increment buffer location until a graph character or an EOL is matched.
*
* @see f_utf_character_is_graph()
*/
-#ifndef _di_fl_utf_string_dynamic_seek_line_until_graph_
- extern f_status_t fl_utf_string_dynamic_seek_line_until_graph(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t placeholder);
-#endif // _di_fl_utf_string_dynamic_seek_line_until_graph_
+#ifndef _di_fl_utfl_string_dynamic_seek_line_until_graph_
+ extern f_status_t fl_utfl_string_dynamic_seek_line_until_graph(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t placeholder);
+#endif // _di_fl_utfl_string_dynamic_seek_line_until_graph_
/**
* Increment buffer location until a non-graph character or an EOL is matched.
*
* @see f_utf_character_is_graph()
*/
-#ifndef _di_fl_utf_string_dynamic_seek_line_until_non_graph_
- extern f_status_t fl_utf_string_dynamic_seek_line_until_non_graph(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t placeholder);
-#endif // _di_fl_utf_string_dynamic_seek_line_until_non_graph_
+#ifndef _di_fl_utfl_string_dynamic_seek_line_until_non_graph_
+ extern f_status_t fl_utfl_string_dynamic_seek_line_until_non_graph(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t placeholder);
+#endif // _di_fl_utfl_string_dynamic_seek_line_until_non_graph_
/**
* Seek the buffer location forward until the UTF-8 character is reached.
* F_parameter (with error bit) if a parameter is invalid.
* F_utf (with error bit) if a character in the buffer is an invalid UTF-8 character.
*/
-#ifndef _di_fl_utf_string_dynamic_seek_to_
- extern f_status_t fl_utf_string_dynamic_seek_to(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
-#endif // _di_fl_utf_string_dynamic_seek_to_
+#ifndef _di_fl_utfl_string_dynamic_seek_to_
+ extern f_status_t fl_utfl_string_dynamic_seek_to(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
+#endif // _di_fl_utfl_string_dynamic_seek_to_
/**
* Seek the buffer location forward until the UTF-8 character (1-byte wide) is reached.
* F_utf (with error bit) if a character in the buffer is an invalid UTF-8 character.
* F_parameter (with error bit) if a parameter is invalid.
*/
-#ifndef _di_fl_utf_string_dynamic_seek_to_char_
- extern f_status_t fl_utf_string_dynamic_seek_to_char(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const int8_t seek_to_this);
-#endif // _di_fl_utf_string_dynamic_seek_to_char_
+#ifndef _di_fl_utfl_string_dynamic_seek_to_char_
+ extern f_status_t fl_utfl_string_dynamic_seek_to_char(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const int8_t seek_to_this);
+#endif // _di_fl_utfl_string_dynamic_seek_to_char_
/**
* Seek the buffer location forward until the (4-byte wide) UTF-8 character is reached.
* F_parameter (with error bit) if a parameter is invalid.
* F_utf (with error bit) if character is an invalid UTF-8 character.
*/
-#ifndef _di_fl_utf_string_dynamic_seek_to_utf_character_
- extern f_status_t fl_utf_string_dynamic_seek_to_utf_character(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
-#endif // _di_fl_utf_string_dynamic_seek_to_utf_character_
+#ifndef _di_fl_utfl_string_dynamic_seek_to_utf_character_
+ extern f_status_t fl_utfl_string_dynamic_seek_to_utf_character(const f_utf_string_static_t buffer, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
+#endif // _di_fl_utfl_string_dynamic_seek_to_utf_character_
/**
* Guarantee that an end of UTF-8 string (NULL) exists at the end of the string.
*
* @see f_utf_character_is_whitespace()
*/
-#ifndef _di_fl_utf_string_rip_
- extern f_status_t fl_utf_string_rip(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination);
-#endif // _di_fl_utf_string_rip_
+#ifndef _di_fl_utfl_string_rip_
+ extern f_status_t fl_utfl_string_rip(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination);
+#endif // _di_fl_utfl_string_rip_
/**
* Allocate a new UTF-8 string from the provided range in the string.
*
* @see f_utf_character_is_whitespace()
*/
-#ifndef _di_fl_utf_string_rip_nulless_
- extern f_status_t fl_utf_string_rip_nulless(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination);
-#endif // _di_fl_utf_string_rip_nulless_
+#ifndef _di_fl_utfl_string_rip_nulless_
+ extern f_status_t fl_utfl_string_rip_nulless(const f_utf_string_t source, const f_utf_string_length_t length, f_utf_string_dynamic_t *destination);
+#endif // _di_fl_utfl_string_rip_nulless_
/**
* Seek the UTF-8 string location forward until the character (1-byte wide) or EOL is reached.
* F_data_not_stop if range.start > range.stop.
* F_parameter (with error bit) if a parameter is invalid.
*/
-#ifndef _di_fl_utf_string_seek_line_to_
- extern f_status_t fl_utf_string_seek_line_to(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
-#endif // _di_fl_utf_string_seek_line_to_
+#ifndef _di_fl_utfl_string_seek_line_to_
+ extern f_status_t fl_utfl_string_seek_line_to(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
+#endif // _di_fl_utfl_string_seek_line_to_
/**
* Seek the string location forward until the 1-byte wide character or EOL is reached.
* F_parameter (with error bit) if a parameter is invalid.
* F_utf (with error bit) if a character in the buffer is an invalid UTF-8 character.
*/
-#ifndef _di_fl_utf_string_seek_line_to_char_
- extern f_status_t fl_utf_string_seek_line_to_char(const f_utf_string_t string, f_utf_string_range_t *range, const int8_t seek_to_this);
-#endif // _di_fl_utf_string_seek_line_to_char_
+#ifndef _di_fl_utfl_string_seek_line_to_char_
+ extern f_status_t fl_utfl_string_seek_line_to_char(const f_utf_string_t string, f_utf_string_range_t *range, const int8_t seek_to_this);
+#endif // _di_fl_utfl_string_seek_line_to_char_
/**
* Increment string location until a UTF-8 graph character or an EOL is matched.
*
* @see f_utf_character_is_graph()
*/
-#ifndef _di_fl_utf_string_seek_line_until_graph_
- extern f_status_t fl_utf_string_seek_line_until_graph(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t placeholder);
-#endif // _di_fl_utf_string_seek_line_until_graph_
+#ifndef _di_fl_utfl_string_seek_line_until_graph_
+ extern f_status_t fl_utfl_string_seek_line_until_graph(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t placeholder);
+#endif // _di_fl_utfl_string_seek_line_until_graph_
/**
* Increment string location until a non-graph UTF-8 character or an EOL is matched.
*
* @see f_utf_character_is_graph()
*/
-#ifndef _di_fl_utf_string_seek_line_until_non_graph_
- extern f_status_t fl_utf_string_seek_line_until_non_graph(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t placeholder);
-#endif // _di_fl_utf_string_seek_line_until_non_graph_
+#ifndef _di_fl_utfl_string_seek_line_until_non_graph_
+ extern f_status_t fl_utfl_string_seek_line_until_non_graph(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t placeholder);
+#endif // _di_fl_utfl_string_seek_line_until_non_graph_
/**
* Seek the string location forward until the character (1-byte wide) is reached.
* F_parameter (with error bit) if a parameter is invalid.
* F_utf (with error bit) if a character in the buffer is an invalid UTF-8 character.
*/
-#ifndef _di_fl_utf_string_seek_to_
- extern f_status_t fl_utf_string_seek_to(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
-#endif // _di_fl_utf_string_seek_to_
+#ifndef _di_fl_utfl_string_seek_to_
+ extern f_status_t fl_utfl_string_seek_to(const f_utf_string_t string, f_utf_string_range_t *range, const f_utf_character_t seek_to_this);
+#endif // _di_fl_utfl_string_seek_to_
/**
* Seek the string location forward until the UTF-8 character (up to 4-byte wide) is reached.
* F_parameter (with error bit) if a parameter is invalid.
* F_utf (with error bit) if a character in the buffer is an invalid UTF-8 character.
*/
-#ifndef _di_fl_utf_string_seek_to_character_
- extern f_status_t fl_utf_string_seek_to_char(const f_utf_string_t string, f_utf_string_range_t *range, const int8_t seek_to_this);
+#ifndef _di_fl_utfl_string_seek_to_character_
+ extern f_status_t fl_utfl_string_seek_to_char(const f_utf_string_t string, f_utf_string_range_t *range, const int8_t seek_to_this);
#endif // _di_fl_utf_string__seek_to_character_
#ifdef __cplusplus
return F_data_not;
}
- f_status_t status = fl_string_maps_increase(environment);
+ f_status_t status = f_string_maps_increase(environment);
if (F_status_is_error(status)) return status;
environment->array[environment->used].name.used = 0;
const f_string_static_t name_string = f_macro_string_static_t_initialize(name, length);
- status = fl_string_dynamic_append_nulless(name_string, &environment->array[environment->used].name);
+ status = f_string_dynamic_append_nulless(name_string, &environment->array[environment->used].name);
if (F_status_is_error(status)) return status;
status = f_environment_get_dynamic(name_string, &environment->array[environment->used].value);
return F_data_not;
}
- f_status_t status = fl_string_maps_increase_by(names.used, environment);
+ f_status_t status = f_string_maps_increase_by(names.used, environment);
if (F_status_is_error(status)) return status;
for (f_array_length_t i = 0; i < names.used; ++i) {
environment->array[environment->used].name.used = 0;
environment->array[environment->used].value.used = 0;
- status = fl_string_dynamic_append_nulless(names.array[i], &environment->array[environment->used].name);
+ status = f_string_dynamic_append_nulless(names.array[i], &environment->array[environment->used].name);
if (F_status_is_error(status)) return status;
status = f_environment_get_dynamic(names.array[i], &environment->array[environment->used].value);
* F_exist_not if name does not exist.
*
* Errors (with error bit) from: f_environment_get_dynamic().
- * Errors (with error bit) from: fl_string_dynamic_append_nulless().
- * Errors (with error bit) from: fl_string_maps_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_append_nulless().
+ * Errors (with error bit) from: f_string_maps_increase_by().
*
* @see f_environment_get_dynamic()
- * @see fl_string_dynamic_append_nulless()
- * @see fl_string_maps_increase_by()
+ * @see f_string_dynamic_append_nulless()
+ * @see f_string_maps_increase_by()
*/
#ifndef _di_fll_environment_load_name_
extern f_status_t fll_environment_load_name(const f_string_t name, const f_string_length_t length, f_string_maps_t *environment);
* F_data_not if names.used is 0.
*
* Errors (with error bit) from: f_environment_get_dynamic().
- * Errors (with error bit) from: fl_string_dynamic_append_nulless().
- * Errors (with error bit) from: fl_string_maps_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_append_nulless().
+ * Errors (with error bit) from: f_string_maps_increase_by().
*
* @see f_environment_get_dynamic()
- * @see fl_string_dynamic_append_nulless()
- * @see fl_string_maps_increase_by()
+ * @see f_string_dynamic_append_nulless()
+ * @see f_string_maps_increase_by()
*/
#ifndef _di_fll_environment_load_names_
extern f_status_t fll_environment_load_names(const f_string_dynamics_t names, f_string_maps_t *environment);
}
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&path);
- fl_string_dynamics_delete(&paths);
+ f_string_dynamic_delete(&path);
+ f_string_dynamics_delete(&paths);
return status;
}
- status = fl_string_dynamic_delete(&path);
+ status = f_string_dynamic_delete(&path);
if (F_status_is_error(status)) {
f_macro_string_dynamics_t_delete_simple(paths);
for (f_array_length_t i = 0; i < paths.used; i++) {
- status = fl_string_append(program_name, name_size, &paths.array[i]);
+ status = f_string_append(program_name, name_size, &paths.array[i]);
if (F_status_is_error_not(status)) {
- status = fl_string_dynamic_terminate(&paths.array[i]);
+ status = f_string_dynamic_terminate(&paths.array[i]);
}
if (F_status_is_error_not(status)) {
}
if (F_status_is_error(status)) {
- fl_string_dynamics_delete(&paths);
+ f_string_dynamics_delete(&paths);
return status;
}
} // for
if (!found) {
- fl_string_dynamics_delete(&paths);
+ f_string_dynamics_delete(&paths);
return F_status_set_error(F_file_found_not);
}
memcpy(&program_path, found->string, found->used);
- status = fl_string_dynamics_delete(&paths);
+ status = f_string_dynamics_delete(&paths);
if (F_status_is_error(status)) return status;
if (parameter && parameter->data) {
* F_none on success.
*
* Errors (with error bit) from: f_macro_string_dynamics_t_resize().
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
* @see f_macro_string_dynamics_t_resize()
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_fll_execute_arguments_add_
extern f_status_t fll_execute_arguments_add(const f_string_t source, const f_string_length_t length, f_string_dynamics_t *arguments);
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_fll_execute_arguments_add_parameter_
extern f_status_t fll_execute_arguments_add_parameter(const f_string_t prefix, const f_string_length_t prefix_length, const f_string_t name, const f_string_length_t name_length, const f_string_t value, const f_string_length_t value_length, f_string_dynamics_t *arguments);
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_fll_execute_arguments_add_parameter_set_
extern f_status_t fll_execute_arguments_add_parameter_set(const f_string_t prefix[], const f_string_length_t prefix_length[], const f_string_t name[], const f_string_length_t name_length[], const f_string_t value[], const f_string_length_t value_length[], const f_array_length_t size, f_string_dynamics_t *arguments);
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_fll_execute_arguments_add_set_
extern f_status_t fll_execute_arguments_add_set(const f_string_t source[], const f_string_length_t length[], const f_array_length_t size, f_string_dynamics_t *arguments);
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_fll_execute_arguments_dynamic_add_
extern f_status_t fll_execute_arguments_dynamic_add(const f_string_static_t source, f_string_dynamics_t *arguments);
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_fll_execute_arguments_dynamic_add_parameter_
extern f_status_t fll_execute_arguments_dynamic_add_parameter(const f_string_static_t prefix, const f_string_static_t name, const f_string_static_t value, f_string_dynamics_t *arguments);
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_fll_execute_arguments_dynamic_add_parameter_set_
extern f_status_t fll_execute_arguments_dynamic_add_parameter_set(const f_string_static_t prefix[], const f_string_static_t name[], const f_string_static_t value[], const f_array_length_t size, f_string_dynamics_t *arguments);
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_fll_execute_arguments_dynamic_add_set_
extern f_status_t fll_execute_arguments_dynamic_add_set(const f_string_static_t source[], const f_array_length_t size, f_string_dynamics_t *arguments);
* Errors (with error bit) from: f_signal_mask().
* Errors (with error bit) from: f_thread_signal_mask().
* Errors (with error bit) from: fl_environment_path_explode_dynamic().
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
*
* @see close()
* @see clearenv()
* @see f_thread_signal_mask()
* @see fl_control_group_apply()
* @see fl_environment_path_explode_dynamic()
- * @see fl_string_append()
- * @see fl_string_dynamic_terminate()
+ * @see f_string_append()
+ * @see f_string_dynamic_terminate()
*/
#ifndef _di_fll_execute_program_
extern f_status_t fll_execute_program(const f_string_t program, const f_string_statics_t arguments, fl_execute_parameter_t * const parameter, fl_execute_as_t * const as, int *result);
#if !defined(_di_fll_execute_arguments_add_) || !defined(_di_fll_execute_arguments_add_set_) || !defined(_di_fll_execute_arguments_dynamic_add_) || !defined(_di_fll_execute_arguments_dynamic_add_set_)
f_status_t private_fll_execute_arguments_add(const f_string_t source, const f_string_length_t length, f_string_dynamics_t *arguments) {
- f_status_t status = fl_string_dynamics_increase(arguments);
+ f_status_t status = f_string_dynamics_increase(arguments);
if (F_status_is_error(status)) return status;
f_string_dynamic_t argument = f_string_dynamic_t_initialize;
if (length) {
- status = fl_string_append(source, length, &argument);
+ status = f_string_append(source, length, &argument);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
return status;
}
}
- status = fl_string_dynamic_terminate(&argument);
+ status = f_string_dynamic_terminate(&argument);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
return status;
}
#if !defined(_di_fll_execute_arguments_add_parameter_) || !defined(_di_fll_execute_arguments_add_parameter_set_) || !defined(_di_fll_execute_arguments_dynamic_add_parameter_) || !defined(_di_fll_execute_arguments_dynamic_add_parameter_set_)
f_status_t private_fll_execute_arguments_add_parameter(const f_string_t prefix, const f_string_length_t prefix_length, const f_string_t name, const f_string_length_t name_length, const f_string_t value, const f_string_length_t value_length, f_string_dynamics_t *arguments) {
- f_status_t status = fl_string_dynamics_increase(arguments);
+ f_status_t status = f_string_dynamics_increase(arguments);
if (F_status_is_error(status)) return status;
f_string_dynamic_t argument = f_string_dynamic_t_initialize;
if (prefix_length) {
- status = fl_string_append(prefix, prefix_length, &argument);
+ status = f_string_append(prefix, prefix_length, &argument);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
return status;
}
}
if (name_length) {
- status = fl_string_append(name, name_length, &argument);
+ status = f_string_append(name, name_length, &argument);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
return status;
}
}
- status = fl_string_dynamic_terminate(&argument);
+ status = f_string_dynamic_terminate(&argument);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
return status;
}
f_macro_string_dynamic_t_clear(argument);
if (value_length) {
- status = fl_string_append(value, value_length, &argument);
+ status = f_string_append(value, value_length, &argument);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
return status;
}
}
- status = fl_string_dynamic_terminate(&argument);
+ status = f_string_dynamic_terminate(&argument);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
return status;
}
- status = fl_string_dynamics_increase(arguments);
+ status = f_string_dynamics_increase(arguments);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
return status;
}
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
- *
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
+ *
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
* @see fll_execute_arguments_add()
* @see fll_execute_arguments_add_set()
* @see fll_execute_arguments_dynamic_add()
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_delete().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_delete().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
- * @see fl_string_append()
- * @see fl_string_dynamic_delete()
- * @see fl_string_dynamic_terminate()
- * @see fl_string_dynamics_increase()
+ * @see f_string_append()
+ * @see f_string_dynamic_delete()
+ * @see f_string_dynamic_terminate()
+ * @see f_string_dynamics_increase()
* @see fll_execute_arguments_add_parameter()
* @see fll_execute_arguments_add_parameter_set()
* @see fll_execute_arguments_dynamic_add_parameter()
if (!contents.array[i].used) continue;
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], values[j]);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], values[j]);
if (F_status_is_error(status)) return status;
if (indexs) {
for (k = 0; k < contents.array[i].used; k++) {
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[k], &values[j]->array[values[j]->used]);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[k], &values[j]->array[values[j]->used]);
if (F_status_is_error(status)) return status;
values[j]->used++;
if (F_status_is_error(status)) return status;
if (status == F_equal_to_not) continue;
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &name);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &name);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
status = fl_string_compare_trim(buffer.string + contents.array[i].array[0].start, values[j]->array[k].name.string, length_name, values[j]->array[k].name.used);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
if (status == F_equal_to) {
matched = F_true;
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
break;
}
} // for
if (values[j]->used == values[j]->size) {
if (values[j]->used + f_fss_default_allocation_step > f_array_length_t_size) {
if (values[j]->used == f_array_length_t_size) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return F_status_set_error(F_array_too_large);
}
f_macro_string_maps_t_resize(status, (*values[j]), values[j]->used + 1);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
f_macro_string_maps_t_resize(status, (*values[j]), values[j]->used + f_fss_default_allocation_step);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
map = &values[j]->array[values[j]->used];
if (contents.array[i].used > 1) {
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[1], &map->value);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[1], &map->value);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
}
} // for
} // for
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return F_none;
}
#endif // _di_fll_fss_snatch_map_
map_multi = &values[j]->array[values[j]->used];
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &map_multi->name);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &map_multi->name);
if (F_status_is_error(status)) return status;
values[j]->used++;
for (k = 1; k < contents.array[i].used; k++) {
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[k], &map_multi->value.array[map_multi->value.used]);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[k], &map_multi->value.array[map_multi->value.used]);
if (F_status_is_error(status)) return status;
map_multi->value.used++;
map = &values[j]->array[values[j]->used];
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &map->name);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &map->name);
if (F_status_is_error(status)) return status;
values[j]->used++;
if (contents.array[i].used > 1) {
for (k = 1; k < contents.array[i].used; k++) {
- status = fl_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], &map->value);
+ status = f_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], &map->value);
if (F_status_is_error(status)) return status;
} // for
}
if (F_status_is_error(status)) return status;
if (status == F_equal_to_not) continue;
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &name);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &name);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
status = fl_string_compare_trim(buffer.string + contents.array[i].array[0].start, values[j]->array[k].name.string, length_name, values[j]->array[k].name.used);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
for (k = 1; k < contents.array[i].used; k++) {
- status = fl_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], &map_multi->value.array[map_multi->value.used]);
+ status = f_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], &map_multi->value.array[map_multi->value.used]);
if (F_status_is_error(status)) return status;
} // for
} // for
} // for
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return F_none;
}
#endif // _di_fll_fss_snatch_map_mash_apart_
if (F_status_is_error(status)) return status;
if (status == F_equal_to_not) continue;
- status = fl_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &name);
+ status = f_string_dynamic_partial_append_nulless(buffer, contents.array[i].array[0], &name);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
status = fl_string_compare_trim(buffer.string + contents.array[i].array[0].start, values[j]->array[k].name.string, length_name, values[j]->array[k].name.used);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
if (status == F_equal_to) {
matched = F_true;
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
break;
}
} // for
if (values[j]->used == values[j]->size) {
if (values[j]->used + f_fss_default_allocation_step > f_array_length_t_size) {
if (values[j]->used == f_array_length_t_size) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return F_status_set_error(F_array_too_large);
}
f_macro_string_maps_t_resize(status, (*values[j]), values[j]->used + 1);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
f_macro_string_maps_t_resize(status, (*values[j]), values[j]->used + f_fss_default_allocation_step);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
}
if (contents.array[i].used > 1) {
- status = fl_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[1], &map->value);
+ status = f_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[1], &map->value);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
}
} // for
} // for
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return F_none;
}
#endif // _di_fll_fss_snatch_map_together_
for (k = 0; k < contents.array[i].used; k++) {
- status = fl_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], values[j]);
+ status = f_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], values[j]);
if (F_status_is_error(status)) return status;
} // for
for (k = 0; k < contents.array[i].used; k++) {
- status = fl_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], &values[j]->array[values[j]->used]);
+ status = f_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], &values[j]->array[values[j]->used]);
if (F_status_is_error(status)) return status;
} // for
for (k = 0; k < contents.array[i].used; k++) {
- status = fl_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], values[j]);
+ status = f_string_dynamic_partial_mash_nulless(glue, glue_length, buffer, contents.array[i].array[k], values[j]);
if (F_status_is_error(status)) return status;
} // for
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
*
* @see fl_string_compare_trim()
- * @see fl_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_partial_append_nulless()
*/
#ifndef _di_fll_fss_snatch_
extern f_status_t fll_fss_snatch(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, f_string_dynamic_t *values[], f_array_length_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
*
* @see fl_string_compare_trim()
- * @see fl_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_partial_append_nulless()
*/
#ifndef _di_fll_fss_snatch_apart_
extern f_status_t fll_fss_snatch_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, f_string_dynamics_t *values[], f_array_lengths_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
*
* @see fl_string_compare_trim()
- * @see fl_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_partial_append_nulless()
*/
#ifndef _di_fll_fss_snatch_map_
extern f_status_t fll_fss_snatch_map(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, f_string_maps_t *values[], f_array_lengths_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
*
* @see fl_string_compare_trim()
- * @see fl_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_partial_append_nulless()
*/
#ifndef _di_fll_fss_snatch_map_apart_
extern f_status_t fll_fss_snatch_map_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, f_string_map_multis_t *values[], f_array_lengths_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_mash_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_mash_nulless().
*/
#ifndef _di_fll_fss_snatch_map_mash_
extern f_status_t fll_fss_snatch_map_mash(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, const f_string_t glue, const f_string_length_t glue_length, f_string_maps_t *values[], f_array_lengths_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
*
* @see fl_string_compare_trim()
- * @see fl_string_dynamic_partial_mash_nulless()
+ * @see f_string_dynamic_partial_mash_nulless()
*/
#ifndef _di_fll_fss_snatch_map_mash_apart_
extern f_status_t fll_fss_snatch_map_mash_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, const f_string_t glue, const f_string_length_t glue_length, f_string_map_multis_t *values[], f_array_lengths_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
*
* @see fl_string_compare_trim()
- * @see fl_string_dynamic_partial_mash_nulless()
+ * @see f_string_dynamic_partial_mash_nulless()
*/
#ifndef _di_fll_fss_snatch_map_together_
extern f_status_t fll_fss_snatch_map_together(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, const f_string_t glue, const f_string_length_t glue_length, f_string_maps_t *values[], f_array_lengths_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_mash_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_mash_nulless().
*/
#ifndef _di_fll_fss_snatch_mash_
extern f_status_t fll_fss_snatch_mash(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, const f_string_t glue, const f_string_length_t glue_length, f_string_dynamic_t *values[], f_array_length_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
*
* @see fl_string_compare_trim()
- * @see fl_string_dynamic_partial_mash_nulless()
+ * @see f_string_dynamic_partial_mash_nulless()
*/
#ifndef _di_fll_fss_snatch_mash_apart_
extern f_status_t fll_fss_snatch_mash_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, const f_string_t glue, const f_string_length_t glue_length, f_string_dynamics_t *values[], f_array_lengths_t *indexs[]);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: fl_string_compare_trim().
- * Errors (with error bit) from: fl_string_dynamic_partial_mash_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_mash_nulless().
*
* @see fl_string_compare_trim()
- * @see fl_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_partial_append_nulless()
*/
#ifndef _di_fll_fss_snatch_together_
extern f_status_t fll_fss_snatch_together(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_t names[], const f_string_length_t lengths[], const f_string_length_t size, const f_string_t glue, const f_string_length_t glue_length, f_string_dynamic_t *values[], f_array_length_t *indexs[]);
}
else {
if (destination->used + 1 > destination->size) {
- status = fl_string_dynamic_increase_by(f_fss_default_allocation_step, destination);
+ status = f_string_dynamic_increase_by(f_fss_default_allocation_step, destination);
if (F_status_is_error(status)) return status;
}
*
* Errors (with error bit) from: fl_fss_basic_content_write_string().
* Errors (with error bit) from: fl_fss_basic_object_write_string().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_fss_basic_write_string_
extern f_status_t fll_fss_basic_write_string(const f_string_static_t object, const f_string_static_t content, const f_fss_quote_t quote, f_string_dynamic_t *destination);
*
* Errors (with error bit) from: fl_fss_basic_list_content_write_string().
* Errors (with error bit) from: fl_fss_basic_list_object_write_string().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_fss_basic_list_write_string_
extern f_status_t fll_fss_basic_list_write_string(const f_string_static_t object, const f_string_static_t content, const f_string_static_t *content_prepend, f_string_dynamic_t *destination);
*
* Errors (with error bit) from: fl_fss_embedded_list_content_write_string().
* Errors (with error bit) from: fl_fss_embedded_list_object_write_string().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_fss_embedded_list_write_string_
extern f_status_t fll_fss_embedded_list_write_string(const f_string_static_t object, const f_string_static_t content, const f_string_static_t *content_prepend, const f_string_ranges_t *ignore, f_string_dynamic_t *destination);
*
* Errors (with error bit) from: fl_fss_extended_content_write_string().
* Errors (with error bit) from: fl_fss_extended_object_write_string().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_fss_extended_write_string_
extern f_status_t fll_fss_extended_write_string(const f_string_static_t object, const f_string_statics_t contents, const f_fss_quote_t quote, f_string_dynamic_t *destination);
*
* Errors (with error bit) from: fl_fss_extended_list_content_write_string().
* Errors (with error bit) from: fl_fss_extended_list_object_write_string().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_fss_extended_list_write_string_
extern f_status_t fll_fss_extended_list_write_string(const f_string_static_t object, const f_string_static_t content, const f_string_static_t *content_prepend, const f_string_ranges_t *ignore, f_string_dynamic_t *destination);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_iki_content_escape_
extern f_status_t fll_iki_content_escape(const f_string_static_t content, const uint8_t quote, f_string_dynamic_t *escaped);
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_iki_content_partial_escape_
extern f_status_t fll_iki_content_partial_escape(const f_string_static_t content, const f_string_range_t range, const uint8_t quote, f_string_dynamic_t *escaped);
* F_syntax (with error bit) if the given string is invalid, such as having an undelimited quote.
*
* Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_iki_content_escape_un_
extern f_status_t fll_iki_content_escape_un(const f_string_static_t content, const uint8_t quote, f_string_dynamic_t *unescaped);
* F_syntax (with error bit) if the given string is invalid, such as having an undelimited quote.
*
* Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#ifndef _di_fll_iki_content_partial_escape_un_
extern f_status_t fll_iki_content_partial_escape_un(const f_string_static_t content, const f_string_range_t range, const uint8_t quote, f_string_dynamic_t *unescaped);
if (content.string[i] == quote) {
if (escaped->used + delimits + 2 > escaped->size) {
- status = fl_string_dynamic_increase_by(delimits + 2, escaped);
+ status = f_string_dynamic_increase_by(delimits + 2, escaped);
if (F_status_is_error(status)) return status;
}
}
else if (content.string[i]) {
if (escaped->used + 1 > escaped->size) {
- status = fl_string_dynamic_increase_by(f_memory_default_allocation_step, escaped);
+ status = f_string_dynamic_increase_by(f_memory_default_allocation_step, escaped);
if (F_status_is_error(status)) return status;
}
// delimits found at the end must be escaped to prevent escaping the end quote.
if (delimits) {
if (escaped->used + delimits > escaped->size) {
- status = fl_string_dynamic_increase_by(delimits, escaped);
+ status = f_string_dynamic_increase_by(delimits, escaped);
if (F_status_is_error(status)) return status;
}
delimits /= 2;
if (unescaped->used + delimits + 1 > unescaped->size) {
- status = fl_string_dynamic_increase_by(delimits + 1, unescaped);
+ status = f_string_dynamic_increase_by(delimits + 1, unescaped);
if (F_status_is_error(status)) return status;
}
}
else if (content.string[j]) {
if (unescaped->used + (j - i) + 1 > unescaped->size) {
- status = fl_string_dynamic_increase_by((j - i) + 1, unescaped);
+ status = f_string_dynamic_increase_by((j - i) + 1, unescaped);
if (F_status_is_error(status)) return status;
}
delimits /= 2;
if (unescaped->used + delimits > unescaped->size) {
- status = fl_string_dynamic_increase_by(delimits, unescaped);
+ status = f_string_dynamic_increase_by(delimits, unescaped);
if (F_status_is_error(status)) return status;
}
}
else if (content.string[i]) {
if (unescaped->used + 1 > unescaped->size) {
- status = fl_string_dynamic_increase_by(f_memory_default_allocation_step, unescaped);
+ status = f_string_dynamic_increase_by(f_memory_default_allocation_step, unescaped);
if (F_status_is_error(status)) return status;
}
* F_parameter (with error bit) if a parameter is invalid.
*
* Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#if !defined(_di_fll_iki_content_escape_) || !defined(_di_fll_iki_content_partial_escape_)
extern f_status_t private_fll_iki_content_partial_escape(const f_string_static_t content, const f_string_range_t range, const uint8_t quote, f_string_dynamic_t *escaped) f_gcc_attribute_visibility_internal;
* F_syntax (with error bit) if the given string is invalid, such as having an undelimited quote.
*
* Errors (with error bit) from: f_macro_string_dynamic_t_resize().
- * Errors (with error bit) from: fl_string_dynamic_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_increase_by().
*/
#if !defined(_di_fll_iki_content_escape_un_) || !defined(_di_fll_iki_content_partial_escape_un_)
extern f_status_t private_fll_iki_content_partial_escape_un(const f_string_static_t content, const f_string_range_t range, const uint8_t quote, f_string_dynamic_t *unescaped) f_gcc_attribute_visibility_internal;
at = 0;
}
- status = fl_string_append_assure("/", 1, canonical);
+ status = f_string_append_assure("/", 1, canonical);
if (F_status_is_error(status)) return status;
for (; path[at]; at++) {
size_chunk++;
if (size_chunk) {
- status = fl_string_append(path + position, size_chunk, canonical);
+ status = f_string_append(path + position, size_chunk, canonical);
if (F_status_is_error(status)) return status;
}
}
}
else if (!(previous_1 == f_path_separator_current_s[0] || previous_1 == f_path_separator_s[0])) {
if (size_chunk) {
- status = fl_string_append(path + position, size_chunk, canonical);
+ status = f_string_append(path + position, size_chunk, canonical);
if (F_status_is_error(status)) return status;
}
}
canonical->used--;
}
- status = fl_string_dynamic_terminate_after(canonical);
+ status = f_string_dynamic_terminate_after(canonical);
if (F_status_is_error(status)) return status;
return F_none;
* F_none on success.
*
* Errors (with error bit) from: f_path_current().
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_append_assure().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_append_assure().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
*/
#ifndef _di_fll_path_canonical_
extern f_status_t fll_path_canonical(const f_string_t path, f_string_dynamic_t *canonical);
if (length > 0) {
f_string_dynamic_t ripped = f_string_dynamic_t_initialize;
- status = fl_string_append(argv[values.array[i]], length, &ripped);
+ status = f_string_append(argv[values.array[i]], length, &ripped);
if (F_status_is_error(status)) return status;
if (status == F_data_not) {
length = strnlen(argv[values.array[i]], f_console_length_size);
if (length > 0) {
- status = fl_string_mash(glue, glue_length, argv[values.array[i]], length, destination);
+ status = f_string_mash(glue, glue_length, argv[values.array[i]], length, destination);
if (F_status_is_error(status)) return F_status_set_error(F_string_too_large);
}
} // for
status = fl_string_rip(argv[values.array[i]], length, &ripped);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&ripped);
+ f_string_dynamic_delete(&ripped);
return status;
}
if (ripped.used > 0) {
- status = fl_string_dynamic_mash(glue, glue_length, ripped, destination);
+ status = f_string_dynamic_mash(glue, glue_length, ripped, destination);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&ripped);
+ f_string_dynamic_delete(&ripped);
return F_status_set_error(F_string_too_large);
}
}
} // for
if (ripped.size) {
- status = fl_string_dynamic_delete(&ripped);
+ status = f_string_dynamic_delete(&ripped);
}
if (status == F_none && start == destination->used) {
* F_memory_not (with error bit) on out of memory.
* F_parameter (with error bit) if a parameter is invalid.
*
- * Errors (with error bit) from: fl_string_append().
+ * Errors (with error bit) from: f_string_append().
*
- * @see fl_string_append()
+ * @see f_string_append()
*/
#ifndef _di_fll_program_parameter_additional_append_
extern f_status_t fll_program_parameter_additional_append(const f_string_t *argv, const f_array_lengths_t values, f_string_dynamics_t *destination);
* F_parameter (with error bit) if a parameter is invalid.
* F_string_too_large (with error bit) if the combined string is too large.
*
- * Errors (with error bit) from: fl_string_mash().
+ * Errors (with error bit) from: f_string_mash().
*
- * @see fl_string_mash()
+ * @see f_string_mash()
*/
#ifndef _di_fll_program_parameter_additional_mash_
extern f_status_t fll_program_parameter_additional_mash(const f_string_t glue, const f_string_length_t glue_length, const f_string_t *argv, const f_array_lengths_t values, f_string_dynamic_t *destination);
* F_parameter (with error bit) if a parameter is invalid.
* F_string_too_large (with error bit) if the combined string is too large.
*
- * Errors (with error bit) from: fl_string_dynamic_mash().
+ * Errors (with error bit) from: f_string_dynamic_mash().
* Errors (with error bit) from: fl_string_rip().
*
- * @see fl_string_dynamic_mash()
+ * @see f_string_dynamic_mash()
* @see fl_string_rip()
*/
#ifndef _di_fll_program_parameter_additional_rip_mash_
}
}
else {
- status = fl_string_append(controller_path_settings, controller_path_settings_length, &setting.path_setting);
+ status = f_string_append(controller_path_settings, controller_path_settings_length, &setting.path_setting);
if (F_status_is_error(status)) {
if (data->error.verbosity != f_console_verbosity_quiet) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append", F_true);
}
}
}
// a pid file path is required.
if (!setting.path_pid.used) {
- status = fl_string_append(controller_path_pid, controller_path_pid_length, &setting.path_pid);
+ status = f_string_append(controller_path_pid, controller_path_pid_length, &setting.path_pid);
if (F_status_is_error_not(status)) {
- status = fl_string_append(entry_name.string, entry_name.used, &setting.path_pid);
+ status = f_string_append(entry_name.string, entry_name.used, &setting.path_pid);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(controller_path_suffix, controller_path_suffix_length, &setting.path_pid);
+ status = f_string_append(controller_path_suffix, controller_path_suffix_length, &setting.path_pid);
}
if (F_status_is_error(status)) {
if (data->error.verbosity != f_console_verbosity_quiet) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append", F_true);
}
}
}
// a control file path is required.
if (!setting.path_control.used) {
- status = fl_string_append(controller_path_control, controller_path_control_length, &setting.path_control);
+ status = f_string_append(controller_path_control, controller_path_control_length, &setting.path_control);
if (F_status_is_error(status)) {
if (data->error.verbosity != f_console_verbosity_quiet) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append", F_true);
}
}
}
}
#define controller_macro_rule_action_t_delete_simple(action) \
- fl_string_dynamics_delete(&action.parameters);
+ f_string_dynamics_delete(&action.parameters);
#endif // _di_controller_rule_action_t_
#ifndef _di_controller_rule_actions_t_
}
#define controller_macro_rule_t_delete_simple(rule) \
- fl_string_dynamic_delete(&rule.id); \
- fl_string_dynamic_delete(&rule.name); \
- fl_string_dynamic_delete(&rule.path); \
- fl_string_dynamic_delete(&rule.script); \
+ f_string_dynamic_delete(&rule.id); \
+ f_string_dynamic_delete(&rule.name); \
+ f_string_dynamic_delete(&rule.path); \
+ f_string_dynamic_delete(&rule.script); \
f_macro_string_maps_t_delete_simple(rule.define) \
f_macro_string_maps_t_delete_simple(rule.parameter) \
- fl_string_dynamics_delete(&rule.environment); \
- fl_string_dynamics_delete(&rule.need); \
- fl_string_dynamics_delete(&rule.want); \
- fl_string_dynamics_delete(&rule.wish); \
+ f_string_dynamics_delete(&rule.environment); \
+ f_string_dynamics_delete(&rule.need); \
+ f_string_dynamics_delete(&rule.want); \
+ f_string_dynamics_delete(&rule.wish); \
fl_type_int32s_delete(&rule.affinity); \
f_capability_delete(&rule.capability); \
fl_control_group_delete(&rule.control_group); \
}
#define controller_macro_entry_action_t_delete_simple(action) \
- fl_string_dynamics_delete(&action.parameters);
+ f_string_dynamics_delete(&action.parameters);
#endif // _di_controller_entry_action_t_
#ifndef _di_controller_entry_actions_t_
}
#define controller_macro_entry_item_t_delete_simple(item) \
- fl_string_dynamic_delete(&item.name); \
+ f_string_dynamic_delete(&item.name); \
controller_macro_entry_actions_t_delete_simple(item.actions)
#endif // _di_controller_entry_item_t_
}
#define controller_macro_setting_t_delete_simple(setting) \
- fl_string_dynamic_delete(&setting.path_control); \
- fl_string_dynamic_delete(&setting.path_pid); \
- fl_string_dynamic_delete(&setting.path_setting); \
+ f_string_dynamic_delete(&setting.path_control); \
+ f_string_dynamic_delete(&setting.path_pid); \
+ f_string_dynamic_delete(&setting.path_setting); \
controller_macro_entry_t_delete_simple(setting.entry) \
controller_macro_rules_t_delete_simple(setting.rules)
#endif // _di_controller_setting_t
f_macro_fss_contents_t_delete_simple(cache.content_items) \
f_macro_fss_objects_t_delete_simple(cache.object_actions) \
f_macro_fss_objects_t_delete_simple(cache.object_items) \
- fl_string_dynamic_delete(&cache.buffer_file); \
- fl_string_dynamic_delete(&cache.buffer_item); \
- fl_string_dynamic_delete(&cache.buffer_other); \
- fl_string_dynamic_delete(&cache.buffer_path); \
- fl_string_dynamic_delete(&cache.name_action); \
- fl_string_dynamic_delete(&cache.name_file); \
- fl_string_dynamic_delete(&cache.name_item);
+ f_string_dynamic_delete(&cache.buffer_file); \
+ f_string_dynamic_delete(&cache.buffer_item); \
+ f_string_dynamic_delete(&cache.buffer_other); \
+ f_string_dynamic_delete(&cache.buffer_path); \
+ f_string_dynamic_delete(&cache.name_action); \
+ f_string_dynamic_delete(&cache.name_file); \
+ f_string_dynamic_delete(&cache.name_item);
#endif // _di_controller_cache_t_
#ifdef __cplusplus
f_status_t status = fl_string_dynamic_rip_nulless(source, range, destination);
if (F_status_is_error(status)) return status;
- return fl_string_dynamic_terminate_after(destination);
+ return f_string_dynamic_terminate_after(destination);
}
#endif // _di_controller_string_dynamic_rip_nulless_terminated_
#ifndef _di_controller_string_dynamic_append_terminated_
f_status_t controller_string_dynamic_append_terminated(const f_string_static_t source, f_string_dynamic_t *destination) {
- f_status_t status = fl_string_dynamic_append(source, destination);
+ f_status_t status = f_string_dynamic_append(source, destination);
if (F_status_is_error(status)) return status;
- return fl_string_dynamic_terminate_after(destination);
+ return f_string_dynamic_terminate_after(destination);
}
#endif // _di_controller_string_dynamic_append_terminated_
#ifndef _di_controller_string_dynamic_partial_append_terminated_
f_status_t controller_string_dynamic_partial_append_terminated(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) {
- f_status_t status = fl_string_dynamic_partial_append(source, range, destination);
+ f_status_t status = f_string_dynamic_partial_append(source, range, destination);
if (F_status_is_error(status)) return status;
- return fl_string_dynamic_terminate_after(destination);
+ return f_string_dynamic_terminate_after(destination);
}
#endif // _di_controller_string_dynamic_partial_append_terminated_
f_macro_time_spec_t_clear(cache->timestamp);
- status = fl_string_append(path_prefix, path_prefix_length, &cache->name_file);
+ status = f_string_append(path_prefix, path_prefix_length, &cache->name_file);
if (F_status_is_error_not(status)) {
- status = fl_string_append(f_path_separator_s, f_path_separator_length, &cache->name_file);
+ status = f_string_append(f_path_separator_s, f_path_separator_length, &cache->name_file);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(path_name.string, path_name.used, &cache->name_file);
+ status = f_string_append(path_name.string, path_name.used, &cache->name_file);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(f_path_extension_separator, f_path_extension_separator_length, &cache->name_file);
+ status = f_string_append(f_path_extension_separator, f_path_extension_separator_length, &cache->name_file);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(path_suffix, path_suffix_length, &cache->name_file);
+ status = f_string_append(path_suffix, path_suffix_length, &cache->name_file);
}
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
- status = fl_string_dynamic_terminate_after(&cache->name_file);
+ status = f_string_dynamic_terminate_after(&cache->name_file);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
return status;
}
status = f_directory_exists(path_directory.string);
}
- fl_string_dynamic_delete(&path_directory);
+ f_string_dynamic_delete(&path_directory);
if (F_status_is_error(status)) return status;
}
}
- fl_string_dynamic_delete(&pid_buffer);
+ f_string_dynamic_delete(&pid_buffer);
}
#endif // _di_controller_file_pid_delete_
if (status == F_number) {
cache->buffer_other.used = 0;
- status = fl_string_dynamic_partial_append_nulless(buffer, range, &cache->buffer_other);
+ status = f_string_dynamic_partial_append_nulless(buffer, range, &cache->buffer_other);
if (F_status_is_error(status)) {
return F_status_set_error(status);
if (status == F_number) {
cache->buffer_other.used = 0;
- status = fl_string_dynamic_partial_append_nulless(buffer, range, &cache->buffer_other);
+ status = f_string_dynamic_partial_append_nulless(buffer, range, &cache->buffer_other);
if (F_status_is_error(status)) {
return F_status_set_error(status);
* F_none on success.
*
* Errors (with error bit) from: fl_string_dynamic_rip_nulless().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
*
* @see fl_string_dynamic_rip_nulless()
- * @see fl_string_dynamic_terminate_after()
+ * @see f_string_dynamic_terminate_after()
*/
#ifndef _di_controller_string_dynamic_rip_nulless_terminated_
extern f_status_t controller_string_dynamic_rip_nulless_terminated(const f_string_static_t source, const f_string_range_t range, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_dynamic_append().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_dynamic_append().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
*
- * @see fl_string_dynamic_append()
- * @see fl_string_dynamic_terminate_after()
+ * @see f_string_dynamic_append()
+ * @see f_string_dynamic_terminate_after()
*/
#ifndef _di_controller_string_dynamic_append_terminated_
extern f_status_t controller_string_dynamic_append_terminated(const f_string_static_t from, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_dynamic_append().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_dynamic_append().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
*
- * @see fl_string_dynamic_append()
- * @see fl_string_dynamic_terminate_after()
+ * @see f_string_dynamic_append()
+ * @see f_string_dynamic_terminate_after()
*/
#ifndef _di_controller_string_dynamic_partial_append_terminated_
extern f_status_t controller_string_dynamic_partial_append_terminated(const f_string_static_t from, const f_string_range_t range, f_string_dynamic_t *destination) f_gcc_attribute_visibility_internal;
* Errors (with error bit) from: f_file_stat().
* Errors (with error bit) from: f_file_stream_open().
* Errors (with error bit) from: f_file_stream_read().
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
*
* @see f_file_stat()
* @see f_file_stream_open()
* @see f_file_stream_read()
- * @see fl_string_append()
- * @see fl_string_dynamic_terminate_after()
+ * @see f_string_append()
+ * @see f_string_dynamic_terminate_after()
*/
#ifndef _di_controller_file_load_
extern f_status_t controller_file_load(const controller_data_t data, const controller_setting_t setting, const f_string_t path_prefix, const f_string_static_t path_name, const f_string_t path_suffix, const f_string_length_t path_prefix_length, const f_string_length_t path_suffix_length, controller_cache_t *cache) f_gcc_attribute_visibility_internal;
* F_recurse (with error bit) on a recursion error.
* F_valid_not (with error bit) on invalid entry item, entry item action, or entry item action value.
*
- * Errors (with error bit) from: fl_string_dynamic_append().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_dynamic_append().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
* Errors (with error bit) from: fl_type_array_lengths_increase_by().
*
* This will detect and report all errors, but only the first error is returned.
* Memory related errors return immediately.
*
- * @see fl_string_dynamic_append()
- * @see fl_string_dynamic_terminate_after()
+ * @see f_string_dynamic_append()
+ * @see f_string_dynamic_terminate_after()
* @see fl_type_array_lengths_increase_by()
*/
#ifndef _di_controller_preprocess_entry_
}
if (allocate) {
- status = fl_string_dynamics_increase_by(allocate, &action->parameters);
+ status = f_string_dynamics_increase_by(allocate, &action->parameters);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase_by", F_true);
action->status = status;
action->parameters.array[j].used = 0;
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_file, cache->content_actions.array[i].array[j], &action->parameters.array[j]);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_file, cache->content_actions.array[i].array[j], &action->parameters.array[j]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
action->status = status;
if (fl_string_dynamic_compare(action->parameters.array[1], cache->buffer_path) == F_equal_to_not) {
if (data.error.verbosity != f_console_verbosity_quiet) {
- status = fl_string_dynamic_terminate_after(&cache->buffer_path);
+ status = f_string_dynamic_terminate_after(&cache->buffer_path);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
action->status = status;
* Errors (with error bit) from: controller_entry_actions_increase_by().
* Errors (with error bit) from: f_fss_count_lines().
* Errors (with error bit) from: fl_fss_apply_delimit().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
* Errors (with error bit) from: fl_string_dynamic_rip_nulless().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
- * Errors (with error bit) from: fl_string_dynamics_increase_by().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_dynamics_increase_by().
* Errors (with error bit) from: fll_fss_extended_read().
*
* @see controller_entry_actions_increase_by()
* @see f_fss_count_lines()
* @see fl_fss_apply_delimit()
- * @see fl_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_partial_append_nulless()
* @see fl_string_dynamic_rip_nulless()
- * @see fl_string_dynamic_terminate_after()
- * @see fl_string_dynamics_increase_by()
+ * @see f_string_dynamic_terminate_after()
+ * @see f_string_dynamics_increase_by()
* @see fll_fss_extended_read()
*/
#ifndef _di_controller_entry_actions_read_
* Errors (with error bit) from: controller_string_dynamic_partial_append_terminated().
* Errors (with error bit) from: f_fss_count_lines().
* Errors (with error bit) from: fl_fss_apply_delimit().
- * Errors (with error bit) from: fl_string_dynamic_append().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
- * Errors (with error bit) from: fl_string_dynamic_terminate().
+ * Errors (with error bit) from: f_string_dynamic_append().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_terminate().
* Errors (with error bit) from: fll_fss_basic_list_read().
*
* @see controller_entry_actions_read()
* @see controller_string_dynamic_partial_append_terminated()
* @see f_fss_count_lines()
* @see fl_fss_apply_delimit()
- * @see fl_string_dynamic_append()
- * @see fl_string_dynamic_partial_append_nulless()
- * @see fl_string_dynamic_terminate()
+ * @see f_string_dynamic_append()
+ * @see f_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_terminate()
* @see fll_fss_basic_list_read()
*/
#ifndef _di_controller_entry_read_
parameters->used = 0;
if (object && object->start <= object->start) {
- status = fl_string_dynamics_increase(parameters);
+ status = f_string_dynamics_increase(parameters);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase", F_true);
return status;
}
parameters->array[parameters->used].used = 0;
- status = fl_string_dynamic_partial_append_nulless(buffer, *object, ¶meters->array[0]);
+ status = f_string_dynamic_partial_append_nulless(buffer, *object, ¶meters->array[0]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
return status;
}
- status = fl_string_dynamic_terminate_after(¶meters->array[0]);
+ status = f_string_dynamic_terminate_after(¶meters->array[0]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
return status;
}
if (content->array[i].start > content->array[i].start) continue;
- status = fl_string_dynamics_increase(parameters);
+ status = f_string_dynamics_increase(parameters);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase", F_true);
return status;
}
parameters->array[parameters->used].used = 0;
- status = fl_string_dynamic_partial_append_nulless(buffer, content->array[i], ¶meters->array[parameters->used]);
+ status = f_string_dynamic_partial_append_nulless(buffer, content->array[i], ¶meters->array[parameters->used]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
return status;
}
- status = fl_string_dynamic_terminate_after(¶meters->array[parameters->used]);
+ status = f_string_dynamic_terminate_after(¶meters->array[parameters->used]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
return status;
}
if (item->type == controller_rule_item_type_script) {
actions->array[actions->used].parameters.used = 0;
- status = fl_string_dynamics_increase(&actions->array[actions->used].parameters);
+ status = f_string_dynamics_increase(&actions->array[actions->used].parameters);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase", F_true);
}
else {
actions->array[actions->used].type = type;
actions->array[actions->used].parameters.used = 0;
actions->array[actions->used].status = F_known_not;
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_action.array[0], &actions->array[actions->used].parameters.array[0]);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_action.array[0], &actions->array[actions->used].parameters.array[0]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_append_nulless", F_true);
}
- status = fl_string_dynamic_terminate_after(&actions->array[actions->used].parameters.array[0]);
+ status = f_string_dynamic_terminate_after(&actions->array[actions->used].parameters.array[0]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
else {
actions->array[actions->used].parameters.used = 1;
actions->array[actions->used].parameters.used = 0;
actions->array[actions->used].status = F_known_not;
- status = fl_string_dynamics_increase(&actions->array[actions->used].parameters);
+ status = f_string_dynamics_increase(&actions->array[actions->used].parameters);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase", F_true);
actions->array[actions->used].status = controller_status_simplify(F_status_set_fine(status));
break;
fll_error_print(data.error, F_status_set_fine(status), "fl_fss_apply_delimit", F_true);
}
else if (item->type == controller_rule_item_type_script) {
- status = fl_string_dynamics_increase(&actions->array[actions->used].parameters);
+ status = f_string_dynamics_increase(&actions->array[actions->used].parameters);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase", F_true);
}
else {
for (f_array_length_t i = 0; i < cache->content_action.used; ++i) {
- status = fl_string_dynamic_partial_mash_nulless(f_string_space_s, f_string_space_length, cache->buffer_item, cache->content_action.array[i], &actions->array[actions->used].parameters.array[0]);
+ status = f_string_dynamic_partial_mash_nulless(f_string_space_s, f_string_space_length, cache->buffer_item, cache->content_action.array[i], &actions->array[actions->used].parameters.array[0]);
if (F_status_is_error(status)) break;
} // for
if (F_status_is_error_not(status)) {
- status = fl_string_dynamic_terminate_after(&actions->array[actions->used].parameters.array[0]);
+ status = f_string_dynamic_terminate_after(&actions->array[actions->used].parameters.array[0]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
else {
actions->array[actions->used].parameters.used = 1;
if (status == F_child || status == F_signal || F_status_is_error(status) && !simulate) break;
} // for
- fl_string_maps_delete(&environment);
+ f_string_maps_delete(&environment);
if (status == F_child) {
return status;
id->used = 0;
- status = fl_string_dynamic_partial_append_nulless(source, directory, id);
+ status = f_string_dynamic_partial_append_nulless(source, directory, id);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
return status;
}
- status = fl_string_append(f_path_separator_s, f_path_separator_length, id);
+ status = f_string_append(f_path_separator_s, f_path_separator_length, id);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
- status = fl_string_dynamic_partial_append_nulless(source, basename, id);
+ status = f_string_dynamic_partial_append_nulless(source, basename, id);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
return status;
}
- status = fl_string_dynamic_terminate_after(id);
+ status = f_string_dynamic_terminate_after(id);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
return status;
path->used = 0;
if (setting.path_setting.used) {
- status = fl_string_append(setting.path_setting.string, setting.path_setting.used, path);
+ status = f_string_append(setting.path_setting.string, setting.path_setting.used, path);
if (F_status_is_error_not(status)) {
- status = fl_string_append(f_path_separator_s, f_path_separator_length, path);
+ status = f_string_append(f_path_separator_s, f_path_separator_length, path);
}
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(controller_string_rules_s, controller_string_rules_length, path);
+ status = f_string_append(controller_string_rules_s, controller_string_rules_length, path);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(f_path_separator_s, f_path_separator_length, path);
+ status = f_string_append(f_path_separator_s, f_path_separator_length, path);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(path_directory.string, path_directory.used, path);
+ status = f_string_append(path_directory.string, path_directory.used, path);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(f_path_separator_s, f_path_separator_length, path);
+ status = f_string_append(f_path_separator_s, f_path_separator_length, path);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(path_name.string, path_name.used, path);
+ status = f_string_append(path_name.string, path_name.used, path);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(f_path_extension_separator_s, f_path_extension_separator_length, path);
+ status = f_string_append(f_path_extension_separator_s, f_path_extension_separator_length, path);
}
if (F_status_is_error_not(status)) {
- status = fl_string_append(controller_string_rule_s, controller_string_rule_length, path);
+ status = f_string_append(controller_string_rule_s, controller_string_rule_length, path);
}
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
- status = fl_string_dynamic_terminate_after(path);
+ status = f_string_dynamic_terminate_after(path);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
return status;
}
cache->name_item.used = 0;
cache->name_file.used = 0;
- status = fl_string_append(controller_string_rules_s, controller_string_rules_length, &cache->name_file);
+ status = f_string_append(controller_string_rules_s, controller_string_rules_length, &cache->name_file);
if (F_status_is_error_not(status)) {
- status = fl_string_append(f_path_separator_s, f_path_separator_length, &cache->name_file);
+ status = f_string_append(f_path_separator_s, f_path_separator_length, &cache->name_file);
}
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append", F_true);
controller_rule_error_print(data->error, *cache, F_true);
return status;
}
- status = fl_string_dynamic_append(setting->rules.array[index].id, &cache->name_file);
+ status = f_string_dynamic_append(setting->rules.array[index].id, &cache->name_file);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_dynamic_append", F_true);
controller_rule_error_print(data->error, *cache, F_true);
return status;
}
- status = fl_string_append(f_path_extension_separator, f_path_extension_separator_length, &cache->name_file);
+ status = f_string_append(f_path_extension_separator, f_path_extension_separator_length, &cache->name_file);
if (F_status_is_error_not(status)) {
- status = fl_string_append(controller_string_rule_s, controller_string_rule_length, &cache->name_file);
+ status = f_string_append(controller_string_rule_s, controller_string_rule_length, &cache->name_file);
}
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append", F_true);
controller_rule_error_print(data->error, *cache, F_true);
return status;
}
- status = fl_string_dynamic_terminate_after(&cache->name_file);
+ status = f_string_dynamic_terminate_after(&cache->name_file);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
controller_rule_error_print(data->error, *cache, F_true);
return status;
cache->name_file.used = 0;
cache->name_item.used = 0;
- status = fl_string_dynamic_append_nulless(rule_id, &rule->id);
+ status = f_string_dynamic_append_nulless(rule_id, &rule->id);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_append_nulless", F_true);
}
else {
- status = fl_string_dynamic_terminate_after(&rule->id);
+ status = f_string_dynamic_terminate_after(&rule->id);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
else {
status = controller_file_load(data, setting, controller_string_rules_s, rule->id, controller_string_rule_s, controller_string_rules_length, controller_string_rule_length, cache);
continue;
}
- status = fl_string_dynamic_partial_append(cache->buffer_file, cache->content_items.array[i].array[0], &cache->buffer_item);
+ status = f_string_dynamic_partial_append(cache->buffer_file, cache->content_items.array[i].array[0], &cache->buffer_item);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append", F_true);
break;
}
- status = fl_string_dynamic_terminate_after(&cache->buffer_item);
+ status = f_string_dynamic_terminate_after(&cache->buffer_item);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
break;
}
// name_item is used to store the setting name.
cache->name_item.used = 0;
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, cache->object_actions.array[i], &cache->name_item);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, cache->object_actions.array[i], &cache->name_item);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
}
else {
- status = fl_string_dynamic_terminate_after(&cache->name_item);
+ status = f_string_dynamic_terminate_after(&cache->name_item);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
}
range2.start = cache->content_actions.array[i].array[0].start;
range2.stop = cache->content_actions.array[i].array[cache->content_actions.array[i].used - 1].stop;
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, range2, &cache->name_action);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, range2, &cache->name_action);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
}
else {
- status = fl_string_dynamic_terminate_after(&cache->name_action);
+ status = f_string_dynamic_terminate_after(&cache->name_action);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
}
setting_maps = &rule->parameter;
}
- status = fl_string_maps_increase(setting_maps);
+ status = f_string_maps_increase(setting_maps);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_maps_increase", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_maps_increase", F_true);
if (F_status_set_fine(status) == F_memory_not) {
status_return = status;
setting_maps->array[setting_maps->used].name.used = 0;
setting_maps->array[setting_maps->used].value.used = 0;
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[0], &setting_maps->array[setting_maps->used].name);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[0], &setting_maps->array[setting_maps->used].name);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
if (F_status_set_fine(status) == F_memory_not) {
status_return = status;
continue;
}
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[1], &setting_maps->array[setting_maps->used].value);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[1], &setting_maps->array[setting_maps->used].value);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
}
else {
- status = fl_string_dynamic_terminate_after(&setting_maps->array[setting_maps->used].value);
+ status = f_string_dynamic_terminate_after(&setting_maps->array[setting_maps->used].value);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
}
rule->control_group.path.used = 0;
// @todo path prefix needs to be configurable via a parameter.
- status = fl_string_append(f_control_group_path_system_prefix, f_control_group_path_system_prefix_length, &rule->control_group.path);
+ status = f_string_append(f_control_group_path_system_prefix, f_control_group_path_system_prefix_length, &rule->control_group.path);
if (F_status_is_error_not(status)) {
- status = fl_string_append(f_control_group_path_system_default, f_control_group_path_system_default_length, &rule->control_group.path);
+ status = f_string_append(f_control_group_path_system_default, f_control_group_path_system_default_length, &rule->control_group.path);
}
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
}
else {
rule->control_group.groups.used = 0;
for (j = 1; j < cache->content_actions.array[i].used; ++j) {
- status = fl_string_dynamics_increase(&rule->control_group.groups);
+ status = f_string_dynamics_increase(&rule->control_group.groups);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase", F_true);
break;
}
rule->control_group.groups.array[rule->control_group.groups.used].used = 0;
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[j], &rule->control_group.groups.array[rule->control_group.groups.used]);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[j], &rule->control_group.groups.array[rule->control_group.groups.used]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
break;
}
}
}
else if (type == controller_rule_setting_type_path) {
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[0], setting_value);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[0], setting_value);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
}
else {
- status = fl_string_dynamic_terminate_after(setting_value);
+ status = f_string_dynamic_terminate_after(setting_value);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
}
if (type == controller_rule_setting_type_capability) {
cache->buffer_other.used = 0;
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[0], &cache->buffer_other);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[0], &cache->buffer_other);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
// get the current line number within the settings item.
cache->line_item = line_item;
}
}
- status = fl_string_dynamic_terminate_after(&cache->buffer_other);
+ status = f_string_dynamic_terminate_after(&cache->buffer_other);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
// get the current line number within the settings item.
cache->line_item = line_item;
for (j = 0; j < cache->content_actions.array[i].used; ++j) {
- status = fl_string_dynamics_increase(setting_values);
+ status = f_string_dynamics_increase(setting_values);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase", F_true);
if (F_status_set_fine(status) == F_memory_not) {
status_return = status;
setting_values->array[setting_values->used].used = 0;
- status = fl_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[j], &setting_values->array[setting_values->used]);
+ status = f_string_dynamic_partial_append_nulless(cache->buffer_item, cache->content_actions.array[i].array[j], &setting_values->array[setting_values->used]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
}
else {
- status = fl_string_dynamic_terminate_after(&setting_values->array[setting_values->used]);
+ status = f_string_dynamic_terminate_after(&setting_values->array[setting_values->used]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
}
}
setting_values = &rule->wish;
}
- status = fl_string_dynamics_increase_by(controller_default_allocation_step, setting_values);
+ status = f_string_dynamics_increase_by(controller_default_allocation_step, setting_values);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase_by", F_true);
if (F_status_set_fine(status) == F_memory_not) {
status_return = status;
* F_none on success.
*
* Errors (with error bit) from: f_fss_count_lines().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
- * Errors (with error bit) from: fl_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamics_increase().
*
* @see f_fss_count_lines()
- * @see fl_string_dynamic_partial_append_nulless()
- * @see fl_string_dynamics_increase()
+ * @see f_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamics_increase()
*/
#ifndef _di_controller_rule_parameters_read_
extern f_status_t controller_rule_parameters_read(const controller_data_t data, const f_string_static_t buffer, f_fss_object_t *object, f_fss_content_t *content, f_string_dynamics_t *parameters) f_gcc_attribute_visibility_internal;
* @return
* F_none on success.
*
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
*
* @see f_string_append()
- * @see fl_string_dynamic_partial_append_nulless()
- * @see fl_string_dynamic_terminate_after()
+ * @see f_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_terminate_after()
*/
#ifndef _di_controller_rule_id_construct_
extern f_status_t controller_rule_id_construct(const controller_data_t data, const f_string_static_t source, const f_string_range_t directory, const f_string_range_t basename, f_string_dynamic_t *id) f_gcc_attribute_visibility_internal;
* F_none on success.
*
* Errors (with error bit) from: f_fss_count_lines().
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
*
* @see controller_rule_action_read()
* @see f_fss_count_lines()
- * @see fl_string_dynamic_partial_append_nulless()
- * @see fl_string_dynamic_terminate_after()
+ * @see f_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_terminate_after()
*/
#ifndef _di_controller_rule_item_read_
extern f_status_t controller_rule_item_read(const controller_data_t data, controller_cache_t *cache, controller_rule_item_t *item) f_gcc_attribute_visibility_internal;
*
* Errors (with error bit) from: f_file_stream_open().
* Errors (with error bit) from: f_file_stream_read().
- * Errors (with error bit) from: fl_string_append().
- * Errors (with error bit) from: fl_string_dynamic_terminate_after().
+ * Errors (with error bit) from: f_string_append().
+ * Errors (with error bit) from: f_string_dynamic_terminate_after().
* Errors (with error bit) from: fll_path_canonical().
*
* @see f_file_stat()
* @see f_file_stream_open()
* @see f_file_stream_read()
- * @see fl_string_append()
- * @see fl_string_dynamic_terminate_after()
+ * @see f_string_append()
+ * @see f_string_dynamic_terminate_after()
* @see fll_path_canonical()
*/
#ifndef _di_controller_rule_path_
* @see f_file_stream_read().
* @see f_fss_count_lines().
* @see fl_fss_apply_delimit().
- * @see fl_string_dynamic_partial_append().
- * @see fl_string_dynamic_partial_append_nulless().
- * @see fl_string_dynamic_terminate_after().
+ * @see f_string_dynamic_partial_append().
+ * @see f_string_dynamic_partial_append_nulless().
+ * @see f_string_dynamic_terminate_after().
* @see fll_fss_basic_list_read().
*/
#ifndef _di_controller_rule_read_
* F_none on success.
* F_valid_not (with error bit) on success but there were one or more invalid settings encountered.
*
- * Errors (with error bit) from: fl_string_dynamic_partial_append_nulless().
+ * Errors (with error bit) from: f_string_dynamic_partial_append_nulless().
* Errors (with error bit) from: fl_string_dynamic_rip_nulless().
- * Errors (with error bit) from: fl_string_dynamics_increase().
- * Errors (with error bit) from: fl_string_maps_increase().
+ * Errors (with error bit) from: f_string_dynamics_increase().
+ * Errors (with error bit) from: f_string_maps_increase().
* Errors (with error bit) from: fll_fss_extended_read().
* Errors (with error bit) from: fll_path_canonical().
*
- * @see fl_string_dynamic_partial_append_nulless()
+ * @see f_string_dynamic_partial_append_nulless()
* @see fl_string_dynamic_rip_nulless()
- * @see fl_string_dynamics_increase()
- * @see fl_string_maps_increase()
+ * @see f_string_dynamics_increase()
+ * @see f_string_maps_increase()
* @see fll_fss_extended_read()
* @see fll_path_canonical()
*/
f_macro_string_lengths_t_delete_simple(data->remaining);
- fl_string_dynamics_delete(&data->define);
- fl_string_dynamic_delete(&data->fakefile);
- fl_string_dynamics_delete(&data->mode);
- fl_string_dynamic_delete(&data->process);
- fl_string_dynamic_delete(&data->settings);
-
- fl_string_dynamic_delete(&data->path_build);
- fl_string_dynamic_delete(&data->path_build_documents);
- fl_string_dynamic_delete(&data->path_build_includes);
- fl_string_dynamic_delete(&data->path_build_libraries);
- fl_string_dynamic_delete(&data->path_build_libraries_script);
- fl_string_dynamic_delete(&data->path_build_libraries_shared);
- fl_string_dynamic_delete(&data->path_build_libraries_static);
- fl_string_dynamic_delete(&data->path_build_objects);
- fl_string_dynamic_delete(&data->path_build_programs);
- fl_string_dynamic_delete(&data->path_build_programs_script);
- fl_string_dynamic_delete(&data->path_build_programs_shared);
- fl_string_dynamic_delete(&data->path_build_programs_static);
- fl_string_dynamic_delete(&data->path_build_settings);
- fl_string_dynamic_delete(&data->path_build_stage);
- fl_string_dynamic_delete(&data->path_work);
-
- fl_string_dynamic_delete(&data->path_data);
- fl_string_dynamic_delete(&data->path_data_build);
-
- fl_string_dynamic_delete(&data->path_data_settings);
-
- fl_string_dynamic_delete(&data->path_documents);
-
- fl_string_dynamic_delete(&data->path_licenses);
-
- fl_string_dynamic_delete(&data->path_sources);
- fl_string_dynamic_delete(&data->path_sources_bash);
- fl_string_dynamic_delete(&data->path_sources_c);
- fl_string_dynamic_delete(&data->path_sources_cpp);
- fl_string_dynamic_delete(&data->path_sources_script);
-
- fl_string_dynamic_delete(&data->path_work);
- fl_string_dynamic_delete(&data->path_work_includes);
- fl_string_dynamic_delete(&data->path_work_libraries);
- fl_string_dynamic_delete(&data->path_work_libraries_script);
- fl_string_dynamic_delete(&data->path_work_libraries_shared);
- fl_string_dynamic_delete(&data->path_work_libraries_static);
- fl_string_dynamic_delete(&data->path_work_programs);
- fl_string_dynamic_delete(&data->path_work_programs_script);
- fl_string_dynamic_delete(&data->path_work_programs_shared);
- fl_string_dynamic_delete(&data->path_work_programs_static);
-
- fl_string_dynamic_delete(&data->file_data_build_defines);
- fl_string_dynamic_delete(&data->file_data_build_dependencies);
- fl_string_dynamic_delete(&data->file_data_build_fakefile);
- fl_string_dynamic_delete(&data->file_data_build_settings);
-
- fl_string_dynamic_delete(&data->file_documents_readme);
+ f_string_dynamics_delete(&data->define);
+ f_string_dynamic_delete(&data->fakefile);
+ f_string_dynamics_delete(&data->mode);
+ f_string_dynamic_delete(&data->process);
+ f_string_dynamic_delete(&data->settings);
+
+ f_string_dynamic_delete(&data->path_build);
+ f_string_dynamic_delete(&data->path_build_documents);
+ f_string_dynamic_delete(&data->path_build_includes);
+ f_string_dynamic_delete(&data->path_build_libraries);
+ f_string_dynamic_delete(&data->path_build_libraries_script);
+ f_string_dynamic_delete(&data->path_build_libraries_shared);
+ f_string_dynamic_delete(&data->path_build_libraries_static);
+ f_string_dynamic_delete(&data->path_build_objects);
+ f_string_dynamic_delete(&data->path_build_programs);
+ f_string_dynamic_delete(&data->path_build_programs_script);
+ f_string_dynamic_delete(&data->path_build_programs_shared);
+ f_string_dynamic_delete(&data->path_build_programs_static);
+ f_string_dynamic_delete(&data->path_build_settings);
+ f_string_dynamic_delete(&data->path_build_stage);
+ f_string_dynamic_delete(&data->path_work);
+
+ f_string_dynamic_delete(&data->path_data);
+ f_string_dynamic_delete(&data->path_data_build);
+
+ f_string_dynamic_delete(&data->path_data_settings);
+
+ f_string_dynamic_delete(&data->path_documents);
+
+ f_string_dynamic_delete(&data->path_licenses);
+
+ f_string_dynamic_delete(&data->path_sources);
+ f_string_dynamic_delete(&data->path_sources_bash);
+ f_string_dynamic_delete(&data->path_sources_c);
+ f_string_dynamic_delete(&data->path_sources_cpp);
+ f_string_dynamic_delete(&data->path_sources_script);
+
+ f_string_dynamic_delete(&data->path_work);
+ f_string_dynamic_delete(&data->path_work_includes);
+ f_string_dynamic_delete(&data->path_work_libraries);
+ f_string_dynamic_delete(&data->path_work_libraries_script);
+ f_string_dynamic_delete(&data->path_work_libraries_shared);
+ f_string_dynamic_delete(&data->path_work_libraries_static);
+ f_string_dynamic_delete(&data->path_work_programs);
+ f_string_dynamic_delete(&data->path_work_programs_script);
+ f_string_dynamic_delete(&data->path_work_programs_shared);
+ f_string_dynamic_delete(&data->path_work_programs_static);
+
+ f_string_dynamic_delete(&data->file_data_build_defines);
+ f_string_dynamic_delete(&data->file_data_build_dependencies);
+ f_string_dynamic_delete(&data->file_data_build_fakefile);
+ f_string_dynamic_delete(&data->file_data_build_settings);
+
+ f_string_dynamic_delete(&data->file_documents_readme);
f_macro_color_context_t_delete_simple(data->context);
if (F_status_is_error(*status)) {
fll_error_print(data.error, F_status_set_fine(*status), "f_macro_string_dynamic_t_new", F_true);
- fl_string_dynamic_delete(&path_source);
+ f_string_dynamic_delete(&path_source);
return;
}
path_source.used = source.used;
- *status = fl_string_dynamic_append_nulless(files.array[i], &path_source);
+ *status = f_string_dynamic_append_nulless(files.array[i], &path_source);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
break;
}
- *status = fl_string_dynamic_terminate_after(&path_source);
+ *status = f_string_dynamic_terminate_after(&path_source);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
if (*status == F_true) {
destination_directory.used = 0;
- *status = fl_string_dynamic_append(destination, &destination_directory);
+ *status = f_string_dynamic_append(destination, &destination_directory);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append", F_true);
break;
}
break;
}
- *status = fl_string_dynamic_terminate_after(&destination_directory);
+ *status = f_string_dynamic_terminate_after(&destination_directory);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
destination_file.used = 0;
destination_directory.used = 0;
- *status = fl_string_dynamic_append_nulless(destination, &destination_file);
+ *status = f_string_dynamic_append_nulless(destination, &destination_file);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
break;
}
if (preserve && preserve < path_source.used) {
- *status = fl_string_dynamic_append_nulless(destination, &destination_directory);
+ *status = f_string_dynamic_append_nulless(destination, &destination_directory);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
break;
}
break;
}
- *status = fl_string_dynamic_terminate_after(&destination_directory);
+ *status = f_string_dynamic_terminate_after(&destination_directory);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
break;
}
- *status = fl_string_append(path_source.string + preserve, path_source.used - preserve, &destination_file);
+ *status = f_string_append(path_source.string + preserve, path_source.used - preserve, &destination_file);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
break;
}
}
}
}
- *status = fl_string_dynamic_terminate_after(&destination_file);
+ *status = f_string_dynamic_terminate_after(&destination_file);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
} // for
f_macro_directory_statuss_t_delete_simple(failures);
- fl_string_dynamic_delete(&path_source);
- fl_string_dynamic_delete(&destination_file);
- fl_string_dynamic_delete(&destination_directory);
+ f_string_dynamic_delete(&path_source);
+ f_string_dynamic_delete(&destination_file);
+ f_string_dynamic_delete(&destination_directory);
if (F_status_is_error_not(*status)) {
fake_build_touch(data, file_stage, status);
if (F_status_is_error(*status)) {
fll_error_print(data.error, F_status_set_fine(*status), "fll_execute_arguments_add", F_true);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return 0;
}
if (data.define.used) {
for (f_array_length_t i = 0; i < data.define.used; i++) {
- *status = fl_string_dynamic_mash(f_string_space_s, 1, data.define.array[i], &defines);
+ *status = f_string_dynamic_mash(f_string_space_s, 1, data.define.array[i], &defines);
if (F_status_is_error(*status)) {
break;
} // for
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_mash", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_mash", F_true);
- fl_string_dynamic_delete(&defines);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamic_delete(&defines);
+ f_string_dynamics_delete(&arguments);
return 0;
}
- *status = fl_string_dynamic_terminate_after(&defines);
+ *status = f_string_dynamic_terminate_after(&defines);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
- fl_string_dynamic_delete(&defines);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamic_delete(&defines);
+ f_string_dynamics_delete(&arguments);
return 0;
}
}
*status = fll_execute_arguments_add_parameter_set(parameters_prefix, parameters_prefix_length, parameters_name, parameters_name_length, parameters_value, parameters_value_length, 7, &arguments);
- fl_string_dynamic_delete(&defines);
+ f_string_dynamic_delete(&defines);
if (F_status_is_error(*status)) {
fll_error_print(data.error, F_status_set_fine(*status), "fll_execute_arguments_add_parameter_set", F_true);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return 0;
}
}
f_string_t function = 0;
{
- function = "fl_string_dynamic_append_nulless";
+ function = "f_string_dynamic_append_nulless";
if (process_script.string[0] != '/') {
- *status = fl_string_dynamic_append_nulless(data.path_data_build, &path);
+ *status = f_string_dynamic_append_nulless(data.path_data_build, &path);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_dynamic_append_nulless(process_script, &path);
+ *status = f_string_dynamic_append_nulless(process_script, &path);
}
if (F_status_is_error_not(*status)) {
- function = "fl_string_dynamic_terminate_after";
- *status = fl_string_dynamic_terminate_after(&path);
+ function = "f_string_dynamic_terminate_after";
+ *status = f_string_dynamic_terminate_after(&path);
}
if (F_status_is_error(*status)) {
fll_error_print(data.error, F_status_set_fine(*status), function, F_true);
- fl_string_dynamic_delete(&path);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamic_delete(&path);
+ f_string_dynamics_delete(&arguments);
return 0;
}
}
if (fake_signal_received(data)) {
*status = F_status_set_error(F_signal);
- fl_string_dynamic_delete(&path);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamic_delete(&path);
+ f_string_dynamics_delete(&arguments);
}
else {
// child processes should receive all signals, without blocking.
*status = fll_execute_program(path.string, arguments, ¶meter, 0, &return_code);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
if (fake_signal_received(data)) {
*status = F_status_set_error(F_signal);
}
}
- fl_string_dynamic_delete(&path);
+ f_string_dynamic_delete(&path);
return return_code;
}
}
} // for
- status = fl_string_dynamic_terminate_after(name);
+ status = f_string_dynamic_terminate_after(name);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
return status;
}
if (F_status_is_error(*status)) {
fll_error_print(data.error, F_status_set_fine(*status), "fll_execute_arguments_add", F_true);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return 0;
}
}
if (F_status_is_error(*status)) {
fll_error_print(data.error, F_status_set_fine(*status), "fll_execute_arguments_add", F_true);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return 0;
}
}
{
const int result = fake_execute(data, data_build.environment, data_build.setting.build_compiler, arguments, status);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
if (F_status_is_error(*status)) {
return 0;
}
if (source_path.used) {
- *status = fl_string_dynamic_prepend(data.path_build_objects, &source_path);
+ *status = f_string_dynamic_prepend(data.path_build_objects, &source_path);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_prepend", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_prepend", F_true);
break;
}
- *status = fl_string_append_assure(f_path_separator_s, f_path_separator_length, &source_path);
+ *status = f_string_append_assure(f_path_separator_s, f_path_separator_length, &source_path);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append_assure", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append_assure", F_true);
break;
}
- *status = fl_string_dynamic_terminate_after(&source_path);
+ *status = f_string_dynamic_terminate_after(&source_path);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
result = fake_execute(data, data_build.environment, data_build.setting.build_indexer, arguments, status);
}
- fl_string_dynamic_delete(&file_name);
- fl_string_dynamic_delete(&source_path);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamic_delete(&file_name);
+ f_string_dynamic_delete(&source_path);
+ f_string_dynamics_delete(&arguments);
if (F_status_is_error_not(*status) && *status != F_child) {
fake_build_touch(data, file_stage, status);
f_macro_fss_delimits_t_delete_simple(delimits);
}
- fl_string_dynamic_delete(&buffer);
+ f_string_dynamic_delete(&buffer);
f_macro_fss_objects_t_delete_simple(objects);
f_macro_fss_contents_t_delete_simple(contents);
}
}
for (j = 0; j < fake_build_setting_total; j++) {
- fl_string_dynamic_delete(&settings_mode_name_dynamic[j]);
+ f_string_dynamic_delete(&settings_mode_name_dynamic[j]);
} // for
if (F_status_is_error(*status)) break;
// replace any potential existing value.
settings_single_destination[i]->used = 0;
- *status = fl_string_dynamic_append_nulless(settings_single_source[i]->array[0], settings_single_destination[i]);
+ *status = f_string_dynamic_append_nulless(settings_single_source[i]->array[0], settings_single_destination[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
break;
}
if (settings_single_type[i] == 2) {
- *status = fl_string_append_assure(f_path_separator_s, f_path_separator_length, settings_single_destination[i]);
+ *status = f_string_append_assure(f_path_separator_s, f_path_separator_length, settings_single_destination[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append_assure", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append_assure", F_true);
break;
}
}
- *status = fl_string_dynamic_terminate_after(settings_single_destination[i]);
+ *status = f_string_dynamic_terminate_after(settings_single_destination[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
}
} // for
}
- fl_string_dynamics_delete(&build_compiler);
- fl_string_dynamics_delete(&build_indexer);
- fl_string_dynamics_delete(&build_language);
- fl_string_dynamics_delete(&build_script);
- fl_string_dynamics_delete(&build_shared);
- fl_string_dynamics_delete(&build_static);
- fl_string_dynamics_delete(&path_headers);
- fl_string_dynamics_delete(&path_headers_preserve);
- fl_string_dynamics_delete(&path_language);
- fl_string_dynamics_delete(&path_library_script);
- fl_string_dynamics_delete(&path_library_shared);
- fl_string_dynamics_delete(&path_library_static);
- fl_string_dynamics_delete(&path_program_script);
- fl_string_dynamics_delete(&path_program_shared);
- fl_string_dynamics_delete(&path_program_static);
- fl_string_dynamics_delete(&path_sources);
- fl_string_dynamics_delete(&path_standard);
- fl_string_dynamics_delete(&process_post);
- fl_string_dynamics_delete(&process_pre);
- fl_string_dynamics_delete(&project_name);
- fl_string_dynamics_delete(&search_exclusive);
- fl_string_dynamics_delete(&search_shared);
- fl_string_dynamics_delete(&search_static);
- fl_string_dynamics_delete(&version_major);
- fl_string_dynamics_delete(&version_micro);
- fl_string_dynamics_delete(&version_minor);
- fl_string_dynamics_delete(&version_target);
+ f_string_dynamics_delete(&build_compiler);
+ f_string_dynamics_delete(&build_indexer);
+ f_string_dynamics_delete(&build_language);
+ f_string_dynamics_delete(&build_script);
+ f_string_dynamics_delete(&build_shared);
+ f_string_dynamics_delete(&build_static);
+ f_string_dynamics_delete(&path_headers);
+ f_string_dynamics_delete(&path_headers_preserve);
+ f_string_dynamics_delete(&path_language);
+ f_string_dynamics_delete(&path_library_script);
+ f_string_dynamics_delete(&path_library_shared);
+ f_string_dynamics_delete(&path_library_static);
+ f_string_dynamics_delete(&path_program_script);
+ f_string_dynamics_delete(&path_program_shared);
+ f_string_dynamics_delete(&path_program_static);
+ f_string_dynamics_delete(&path_sources);
+ f_string_dynamics_delete(&path_standard);
+ f_string_dynamics_delete(&process_post);
+ f_string_dynamics_delete(&process_pre);
+ f_string_dynamics_delete(&project_name);
+ f_string_dynamics_delete(&search_exclusive);
+ f_string_dynamics_delete(&search_shared);
+ f_string_dynamics_delete(&search_static);
+ f_string_dynamics_delete(&version_major);
+ f_string_dynamics_delete(&version_micro);
+ f_string_dynamics_delete(&version_minor);
+ f_string_dynamics_delete(&version_target);
}
#endif // _di_fake_build_load_setting_process_
for (uint8_t i = 0; i < 3; i++) {
if (destinations[i]->used > 0) continue;
- *status = fl_string_append_assure(sources[i], lengths[i], destinations[i]);
+ *status = f_string_append_assure(sources[i], lengths[i], destinations[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append_assure", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append_assure", F_true);
break;
}
- *status = fl_string_dynamic_terminate_after(destinations[i]);
+ *status = f_string_dynamic_terminate_after(destinations[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
} // for
for (uint8_t i = 0; i < fake_build_stage_total; i++) {
- *status = fl_string_dynamic_append_nulless(data.path_build_stage, values[i]);
+ *status = f_string_dynamic_append_nulless(data.path_build_stage, values[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
break;
}
if (data.process.used) {
- *status = fl_string_append(data.process.string, data.process.used, values[i]);
+ *status = f_string_append(data.process.string, data.process.used, values[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
break;
}
- *status = fl_string_append(fake_build_stage_separate, fake_build_stage_separate_length, values[i]);
+ *status = f_string_append(fake_build_stage_separate, fake_build_stage_separate_length, values[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
break;
}
}
- *status = fl_string_append_nulless(names[i], lengths[i], values[i]);
+ *status = f_string_append_nulless(names[i], lengths[i], values[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
break;
}
- *status = fl_string_append(fake_build_stage_separate, fake_build_stage_separate_length, values[i]);
+ *status = f_string_append(fake_build_stage_separate, fake_build_stage_separate_length, values[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
break;
}
- *status = fl_string_dynamic_append(settings_file_base, values[i]);
+ *status = f_string_dynamic_append(settings_file_base, values[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append", F_true);
break;
}
- *status = fl_string_append(fake_build_stage_built, fake_build_stage_built_length, values[i]);
+ *status = f_string_append(fake_build_stage_built, fake_build_stage_built_length, values[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
break;
}
- *status = fl_string_dynamic_terminate_after(values[i]);
+ *status = f_string_dynamic_terminate_after(values[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
} // for
- fl_string_dynamic_delete(&settings_file_base);
+ f_string_dynamic_delete(&settings_file_base);
}
#endif // _di_fake_build_load_stage_
}
if (destination_path.used) {
- *status = fl_string_dynamic_prepend(data.path_build_objects, &destination_path);
+ *status = f_string_dynamic_prepend(data.path_build_objects, &destination_path);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_prepend", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_prepend", F_true);
break;
}
- *status = fl_string_append_assure(f_path_separator_s, f_path_separator_length, &destination_path);
+ *status = f_string_append_assure(f_path_separator_s, f_path_separator_length, &destination_path);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append_assure", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append_assure", F_true);
break;
}
- *status = fl_string_dynamic_terminate_after(&destination_path);
+ *status = f_string_dynamic_terminate_after(&destination_path);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
result = fake_execute(data, data_build.environment, data_build.setting.build_compiler, arguments, status);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
if (F_status_is_error(*status) || *status == F_child) break;
} // for
- fl_string_dynamic_delete(&file_name);
- fl_string_dynamic_delete(&destination_path);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamic_delete(&file_name);
+ f_string_dynamic_delete(&destination_path);
+ f_string_dynamics_delete(&arguments);
if (F_status_is_error_not(*status) && *status != F_child) {
fake_build_touch(data, file_stage, status);
if (F_status_is_error(*status)) {
fll_error_print(data.error, F_status_set_fine(*status), "fll_execute_arguments_add", F_true);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return 0;
}
int result = fake_execute(data, data_build.environment, data_build.setting.build_compiler, arguments, status);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
if (F_status_is_error_not(*status) && *status != F_child) {
fake_build_touch(data, file_stage, status);
if (F_status_is_error(*status)) {
fll_error_print(data.error, F_status_set_fine(*status), "fll_execute_arguments_add", F_true);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return 0;
}
int result = fake_execute(data, data_build.environment, data_build.setting.build_compiler, arguments, status);
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
if (F_status_is_error_not(*status) && *status != F_child) {
fake_build_touch(data, file_stage, status);
}
#define fake_macro_build_setting_t_delete_simple(setting) \
- fl_string_dynamic_delete(&setting.build_compiler); \
- fl_string_dynamic_delete(&setting.build_indexer); \
- fl_string_dynamic_delete(&setting.path_headers); \
- fl_string_dynamic_delete(&setting.path_language); \
- fl_string_dynamic_delete(&setting.path_library_script); \
- fl_string_dynamic_delete(&setting.path_library_shared); \
- fl_string_dynamic_delete(&setting.path_library_static); \
- fl_string_dynamic_delete(&setting.path_program_script); \
- fl_string_dynamic_delete(&setting.path_program_shared); \
- fl_string_dynamic_delete(&setting.path_program_static); \
- fl_string_dynamic_delete(&setting.path_sources); \
- fl_string_dynamic_delete(&setting.process_post); \
- fl_string_dynamic_delete(&setting.process_pre); \
- fl_string_dynamic_delete(&setting.project_name); \
- fl_string_dynamic_delete(&setting.version_major); \
- fl_string_dynamic_delete(&setting.version_micro); \
- fl_string_dynamic_delete(&setting.version_minor); \
- fl_string_dynamics_delete(&setting.build_libraries); \
- fl_string_dynamics_delete(&setting.build_sources_headers); \
- fl_string_dynamics_delete(&setting.build_sources_library); \
- fl_string_dynamics_delete(&setting.build_sources_program); \
- fl_string_dynamics_delete(&setting.build_sources_setting); \
- fl_string_dynamics_delete(&setting.build_sources_script); \
- fl_string_dynamics_delete(&setting.defines_all); \
- fl_string_dynamics_delete(&setting.defines_shared); \
- fl_string_dynamics_delete(&setting.defines_static); \
- fl_string_dynamics_delete(&setting.environment); \
- fl_string_dynamics_delete(&setting.flags_all); \
- fl_string_dynamics_delete(&setting.flags_library); \
- fl_string_dynamics_delete(&setting.flags_program); \
- fl_string_dynamics_delete(&setting.flags_shared); \
- fl_string_dynamics_delete(&setting.flags_static); \
- fl_string_dynamics_delete(&setting.modes); \
- fl_string_dynamics_delete(&setting.modes_default);
+ f_string_dynamic_delete(&setting.build_compiler); \
+ f_string_dynamic_delete(&setting.build_indexer); \
+ f_string_dynamic_delete(&setting.path_headers); \
+ f_string_dynamic_delete(&setting.path_language); \
+ f_string_dynamic_delete(&setting.path_library_script); \
+ f_string_dynamic_delete(&setting.path_library_shared); \
+ f_string_dynamic_delete(&setting.path_library_static); \
+ f_string_dynamic_delete(&setting.path_program_script); \
+ f_string_dynamic_delete(&setting.path_program_shared); \
+ f_string_dynamic_delete(&setting.path_program_static); \
+ f_string_dynamic_delete(&setting.path_sources); \
+ f_string_dynamic_delete(&setting.process_post); \
+ f_string_dynamic_delete(&setting.process_pre); \
+ f_string_dynamic_delete(&setting.project_name); \
+ f_string_dynamic_delete(&setting.version_major); \
+ f_string_dynamic_delete(&setting.version_micro); \
+ f_string_dynamic_delete(&setting.version_minor); \
+ f_string_dynamics_delete(&setting.build_libraries); \
+ f_string_dynamics_delete(&setting.build_sources_headers); \
+ f_string_dynamics_delete(&setting.build_sources_library); \
+ f_string_dynamics_delete(&setting.build_sources_program); \
+ f_string_dynamics_delete(&setting.build_sources_setting); \
+ f_string_dynamics_delete(&setting.build_sources_script); \
+ f_string_dynamics_delete(&setting.defines_all); \
+ f_string_dynamics_delete(&setting.defines_shared); \
+ f_string_dynamics_delete(&setting.defines_static); \
+ f_string_dynamics_delete(&setting.environment); \
+ f_string_dynamics_delete(&setting.flags_all); \
+ f_string_dynamics_delete(&setting.flags_library); \
+ f_string_dynamics_delete(&setting.flags_program); \
+ f_string_dynamics_delete(&setting.flags_shared); \
+ f_string_dynamics_delete(&setting.flags_static); \
+ f_string_dynamics_delete(&setting.modes); \
+ f_string_dynamics_delete(&setting.modes_default);
#define fake_build_setting_name_build_compiler "build_compiler"
#define fake_build_setting_name_build_language "build_language"
#define fake_build_stage_total 13
#define fake_macro_build_stage_t_delete_simple(stage) \
- fl_string_dynamic_delete(&stage.file_libraries_script); \
- fl_string_dynamic_delete(&stage.file_libraries_shared); \
- fl_string_dynamic_delete(&stage.file_libraries_static); \
- fl_string_dynamic_delete(&stage.file_objects_static); \
- fl_string_dynamic_delete(&stage.file_process_post); \
- fl_string_dynamic_delete(&stage.file_process_pre); \
- fl_string_dynamic_delete(&stage.file_programs_script); \
- fl_string_dynamic_delete(&stage.file_programs_shared); \
- fl_string_dynamic_delete(&stage.file_programs_static); \
- fl_string_dynamic_delete(&stage.file_skeleton); \
- fl_string_dynamic_delete(&stage.file_sources_headers); \
- fl_string_dynamic_delete(&stage.file_sources_script); \
- fl_string_dynamic_delete(&stage.file_sources_settings);
+ f_string_dynamic_delete(&stage.file_libraries_script); \
+ f_string_dynamic_delete(&stage.file_libraries_shared); \
+ f_string_dynamic_delete(&stage.file_libraries_static); \
+ f_string_dynamic_delete(&stage.file_objects_static); \
+ f_string_dynamic_delete(&stage.file_process_post); \
+ f_string_dynamic_delete(&stage.file_process_pre); \
+ f_string_dynamic_delete(&stage.file_programs_script); \
+ f_string_dynamic_delete(&stage.file_programs_shared); \
+ f_string_dynamic_delete(&stage.file_programs_static); \
+ f_string_dynamic_delete(&stage.file_skeleton); \
+ f_string_dynamic_delete(&stage.file_sources_headers); \
+ f_string_dynamic_delete(&stage.file_sources_script); \
+ f_string_dynamic_delete(&stage.file_sources_settings);
#define fake_build_stage_built ".built"
#define fake_build_stage_libraries_script "libraries_script"
#define fake_macro_build_data_delete_simple(build) \
fake_macro_build_setting_t_delete_simple(build.setting) \
- fl_string_maps_delete(&build.environment);
+ f_string_maps_delete(&build.environment);
#endif // _di_fake_build_data_t_
#ifndef _di_fake_build_parameter_
if (F_status_is_error(status)) {
fll_error_file_print(data.error, F_status_set_fine(status), name_function, F_true, path_file, "allocate buffer size for", fll_error_file_type_file);
- fl_string_dynamic_delete(&(*buffer));
+ f_string_dynamic_delete(&(*buffer));
return status;
}
}
if (F_status_is_error(status)) {
fll_error_file_print(data.error, F_status_set_fine(status), name_function, F_true, path_file, "read", fll_error_file_type_file);
- fl_string_dynamic_delete(&(*buffer));
+ f_string_dynamic_delete(&(*buffer));
}
return status;
};
for (i = 0; i < 15; i++) {
- status = fl_string_append_nulless(parameters_source[i], parameters_length[i], parameters_value[i]);
+ status = f_string_append_nulless(parameters_source[i], parameters_length[i], parameters_value[i]);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append_nulless", F_true);
return status;
}
} // for
};
for (i = 0; i < 11; i++) {
- status = fl_string_append_nulless(parameters_source[i], parameters_length[i], parameters_value[i]);
+ status = f_string_append_nulless(parameters_source[i], parameters_length[i], parameters_value[i]);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append_nulless", F_true);
return status;
}
} // for
};
for (i = 0; i < 3; i++) {
- status = fl_string_dynamic_append_nulless(data->path_work, parameters_value[i]);
+ status = f_string_dynamic_append_nulless(data->path_work, parameters_value[i]);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_dynamic_append_nulless", F_true);
return status;
}
} // for
};
for (i = 0; i < 3; i++) {
- status = fl_string_append_nulless(parameters_source[i], parameters_length[i], parameters_value[i]);
+ status = f_string_append_nulless(parameters_source[i], parameters_length[i], parameters_value[i]);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append_nulless", F_true);
return status;
}
} // for
};
for (i = 0; i < 6; i++) {
- status = fl_string_append_nulless(parameters_source[i], parameters_length[i], parameters_value[i]);
+ status = f_string_append_nulless(parameters_source[i], parameters_length[i], parameters_value[i]);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append_nulless", F_true);
return status;
}
} // for
for (i = 0; i < 34; i++) {
if (!parameters_value[i]->used) continue;
- status = fl_string_dynamic_terminate_after(parameters_value[i]);
+ status = f_string_dynamic_terminate_after(parameters_value[i]);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_dynamic_terminate_after", F_true);
return status;
}
} // for
f_status_t status = F_none;
for (uint8_t i = 0; i < length; i++) {
- status = fl_string_dynamic_append_nulless(source, destination[i]);
+ status = f_string_dynamic_append_nulless(source, destination[i]);
if (F_status_is_error(status)) return status;
} // for
} // for
}
- status = fl_string_append(arguments.argv[location], length, parameters_value[i]);
+ status = f_string_append(arguments.argv[location], length, parameters_value[i]);
if (F_status_is_error(status)) {
if (status == F_status_set_error(F_string_too_large)) {
}
}
else {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append", F_true);
}
return status;
if (F_status_is_error_not(*status)) {
data_make->setting_make.parameter.used = 1;
- function_name = "fl_string_append";
- *status = fl_string_append(fake_make_setting_return, fake_make_setting_return_length, &data_make->setting_make.parameter.array[0].name);
+ function_name = "f_string_append";
+ *status = f_string_append(fake_make_setting_return, fake_make_setting_return_length, &data_make->setting_make.parameter.array[0].name);
}
if (F_status_is_error_not(*status)) {
- function_name = "fl_string_dynamic_terminate_after";
- *status = fl_string_dynamic_terminate_after(&data_make->setting_make.parameter.array[0].name);
+ function_name = "f_string_dynamic_terminate_after";
+ *status = f_string_dynamic_terminate_after(&data_make->setting_make.parameter.array[0].name);
}
if (F_status_is_error_not(*status)) {
}
if (F_status_is_error_not(*status)) {
- function_name = "fl_string_dynamic_terminate_after";
- *status = fl_string_dynamic_terminate_after(&data_make->setting_make.parameter.array[0].value.array[0]);
+ function_name = "f_string_dynamic_terminate_after";
+ *status = f_string_dynamic_terminate_after(&data_make->setting_make.parameter.array[0].value.array[0]);
}
if (F_status_is_error(*status)) {
for (; j < settings.contents.array[i].used; j++) {
- *status = fl_string_dynamic_partial_append_nulless(data_make->buffer, settings.contents.array[i].array[j], &name_define);
+ *status = f_string_dynamic_partial_append_nulless(data_make->buffer, settings.contents.array[i].array[j], &name_define);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_partial_append_nulless", F_true);
break;
}
- *status = fl_string_dynamic_terminate_after(&name_define);
+ *status = f_string_dynamic_terminate_after(&name_define);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
if (k == data_make->setting_build.environment.used) {
if (data_make->setting_build.environment.used + 1 > data_make->setting_build.environment.size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, &data_make->setting_build.environment);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, &data_make->setting_build.environment);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
break;
}
}
// Include the terminating NULL when copying.
name_define.used++;
- *status = fl_string_dynamic_append(name_define, &data_make->setting_build.environment.array[data_make->setting_build.environment.used]);
+ *status = f_string_dynamic_append(name_define, &data_make->setting_build.environment.array[data_make->setting_build.environment.used]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append", F_true);
break;
}
} // for
if (F_status_is_error(*status)) {
- fl_string_dynamic_delete(&name_define);
+ f_string_dynamic_delete(&name_define);
break;
}
*status = F_none;
- fl_string_dynamic_delete(&name_define);
+ f_string_dynamic_delete(&name_define);
}
else if (fl_string_dynamic_partial_compare_string(fake_make_setting_fail, data_make->buffer, fake_make_setting_fail_length, settings.objects.array[i]) == F_equal_to) {
if (unmatched_fail) {
for (f_array_length_t j = 1; j < settings.contents.array[i].used; j++) {
- function_name = "fl_string_dynamic_partial_append_nulless";
- *status = fl_string_dynamic_partial_append_nulless(data_make->buffer, settings.contents.array[i].array[j], &data_make->setting_make.parameter.array[0].value.array[0]);
+ function_name = "f_string_dynamic_partial_append_nulless";
+ *status = f_string_dynamic_partial_append_nulless(data_make->buffer, settings.contents.array[i].array[j], &data_make->setting_make.parameter.array[0].value.array[0]);
if (F_status_is_error_not(*status)) {
- function_name = "fl_string_dynamic_terminate_after";
- *status = fl_string_dynamic_terminate_after(&data_make->setting_make.parameter.array[0].value.array[0]);
+ function_name = "f_string_dynamic_terminate_after";
+ *status = f_string_dynamic_terminate_after(&data_make->setting_make.parameter.array[0].value.array[0]);
}
if (F_status_is_error_not(*status) && j + 1 < settings.contents.array[i].used) {
- function_name = "fl_string_append_assure";
- *status = fl_string_append_assure(f_string_space_s, 1, &data_make->setting_make.parameter.array[0].value.array[0]);
+ function_name = "f_string_append_assure";
+ *status = f_string_append_assure(f_string_space_s, 1, &data_make->setting_make.parameter.array[0].value.array[0]);
}
if (F_status_is_error(*status)) {
// if either compiler or linker is specified, each will replace any existing build_compiler or build_indexer, respectively.
if (range_compiler) {
data_make->setting_build.build_compiler.used = 0;
- *status = fl_string_dynamic_partial_append(data_make->buffer, *range_compiler, &data_make->setting_build.build_compiler);
+ *status = f_string_dynamic_partial_append(data_make->buffer, *range_compiler, &data_make->setting_build.build_compiler);
}
if (F_status_is_error_not(*status) && range_linker) {
data_make->setting_build.build_indexer.used = 0;
- *status = fl_string_dynamic_partial_append(data_make->buffer, *range_linker, &data_make->setting_build.build_indexer);
+ *status = f_string_dynamic_partial_append(data_make->buffer, *range_linker, &data_make->setting_build.build_indexer);
}
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_partial_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_partial_append", F_true);
f_macro_fss_set_t_delete_simple(settings);
return;
for (f_array_length_t j = 0; j < define.array[i].value.used; j++) {
- *status = fl_string_dynamic_mash(f_string_space_s, 1, define.array[i].value.array[j], &combined);
+ *status = f_string_dynamic_mash(f_string_space_s, 1, define.array[i].value.array[j], &combined);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_mash_nulless", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_mash_nulless", F_true);
break;
}
} // for
if (F_status_is_error(*status)) break;
- *status = fl_string_dynamic_terminate_after(&combined);
+ *status = f_string_dynamic_terminate_after(&combined);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
break;
}
}
} // for
- fl_string_dynamic_delete(&combined);
+ f_string_dynamic_delete(&combined);
}
f_macro_string_map_multis_t_delete_simple(define);
if (data.context.mode != f_color_mode_none) {
if (data_make->parameter.color.used >= data_make->parameter.color.size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, &data_make->parameter.color);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, &data_make->parameter.color);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
if (data.context.mode == f_color_mode_no_color) {
if (data.parameters[fake_parameter_no_color].type == f_console_type_normal) {
- *status = fl_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
else if (data.parameters[fake_parameter_no_color].type == f_console_type_inverse) {
- *status = fl_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_append(f_console_standard_short_no_color_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_standard_short_no_color_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
}
else if (data.context.mode == f_color_mode_dark) {
if (data.parameters[fake_parameter_dark].type == f_console_type_normal) {
- *status = fl_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
else if (data.parameters[fake_parameter_dark].type == f_console_type_inverse) {
- *status = fl_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_append(f_console_standard_short_dark_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_standard_short_dark_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
}
else if (data.context.mode == f_color_mode_light) {
if (data.parameters[fake_parameter_light].type == f_console_type_normal) {
- *status = fl_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
else if (data.parameters[fake_parameter_light].type == f_console_type_inverse) {
- *status = fl_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_append(f_console_standard_short_light_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
+ *status = f_string_append(f_console_standard_short_light_s, 1, &data_make->parameter.color.array[data_make->parameter.color.used]);
}
}
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
return;
}
else {
if (data.error.verbosity != f_console_verbosity_normal) {
if (data_make->parameter.verbosity.used >= data_make->parameter.verbosity.size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, &data_make->parameter.verbosity);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, &data_make->parameter.verbosity);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
if (data.error.verbosity == f_console_verbosity_quiet) {
if (data.parameters[fake_parameter_verbosity_quiet].type == f_console_type_normal) {
- *status = fl_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
else if (data.parameters[fake_parameter_verbosity_quiet].type == f_console_type_inverse) {
- *status = fl_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_append(f_console_standard_short_quiet_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_standard_short_quiet_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
}
else if (data.error.verbosity == f_console_verbosity_verbose) {
if (data.parameters[fake_parameter_verbosity_verbose].type == f_console_type_normal) {
- *status = fl_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
else if (data.parameters[fake_parameter_verbosity_verbose].type == f_console_type_inverse) {
- *status = fl_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_append(f_console_standard_short_verbose_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_standard_short_verbose_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
}
else if (data.error.verbosity == f_console_verbosity_debug) {
if (data.parameters[fake_parameter_verbosity_debug].type == f_console_type_normal) {
- *status = fl_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_symbol_short_enable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
else if (data.parameters[fake_parameter_verbosity_debug].type == f_console_type_inverse) {
- *status = fl_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_symbol_short_disable_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_append(f_console_standard_short_debug_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
+ *status = f_string_append(f_console_standard_short_debug_s, 1, &data_make->parameter.verbosity.array[data_make->parameter.verbosity.used]);
}
}
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
return;
}
else {
for (j = 0; j < source[i]->used; j++) {
if (destination[i]->used >= destination[i]->size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, destination[i]);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, destination[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
if (console[i]->type == f_console_type_normal) {
- *status = fl_string_append(f_console_symbol_short_enable_s, 1, &destination[i]->array[destination[i]->used]);
+ *status = f_string_append(f_console_symbol_short_enable_s, 1, &destination[i]->array[destination[i]->used]);
}
else if (console[i]->type == f_console_type_inverse) {
- *status = fl_string_append(f_console_symbol_short_disable_s, 1, &destination[i]->array[destination[i]->used]);
+ *status = f_string_append(f_console_symbol_short_disable_s, 1, &destination[i]->array[destination[i]->used]);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_append(parameter[i], 1, &destination[i]->array[destination[i]->used]);
+ *status = f_string_append(parameter[i], 1, &destination[i]->array[destination[i]->used]);
}
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
return;
}
else {
}
if (destination[i]->used >= destination[i]->size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, destination[i]);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, destination[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
- *status = fl_string_dynamic_append(source[i]->array[j], &destination[i]->array[destination[i]->used]);
+ *status = f_string_dynamic_append(source[i]->array[j], &destination[i]->array[destination[i]->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append", F_true);
return;
}
else {
for (uint8_t i = 0; i < 7; i ++) {
if (destination[i]->used >= destination[i]->size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, destination[i]);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, destination[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
if (console[i]->type == f_console_type_normal) {
- *status = fl_string_append(f_console_symbol_short_enable_s, 1, &destination[i]->array[destination[i]->used]);
+ *status = f_string_append(f_console_symbol_short_enable_s, 1, &destination[i]->array[destination[i]->used]);
}
else if (console[i]->type == f_console_type_inverse) {
- *status = fl_string_append(f_console_symbol_short_disable_s, 1, &destination[i]->array[destination[i]->used]);
+ *status = f_string_append(f_console_symbol_short_disable_s, 1, &destination[i]->array[destination[i]->used]);
}
if (F_status_is_error_not(*status)) {
- *status = fl_string_append(parameter[i], 1, &destination[i]->array[destination[i]->used]);
+ *status = f_string_append(parameter[i], 1, &destination[i]->array[destination[i]->used]);
}
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_append", F_true);
return;
}
else {
}
if (destination[i]->used >= destination[i]->size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, destination[i]);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, destination[i]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
- *status = fl_string_dynamic_append(*source[i], &destination[i]->array[destination[i]->used]);
+ *status = f_string_dynamic_append(*source[i], &destination[i]->array[destination[i]->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data.error, F_status_set_fine(*status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(*status), "f_string_dynamic_append", F_true);
return;
}
else {
// pre-allocate the known arguments size.
if (arguments->used + content.used > arguments->size) {
- *status = fl_string_dynamics_increase_by(content.used, arguments);
+ *status = f_string_dynamics_increase_by(content.used, arguments);
if (F_status_is_error(*status) || *status == F_string_too_large) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
}
if (arguments->used >= arguments->size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
range.start = content.array[i].start;
range.stop = iki_variable.array[0].start - 1;
- *status = fl_string_dynamic_partial_append_nulless(data_make->buffer, range, &arguments->array[arguments->used]);
+ *status = f_string_dynamic_partial_append_nulless(data_make->buffer, range, &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_partial_append_nulless", F_true);
break;
}
}
range.start = previous + 1;
range.stop = iki_variable.array[j].start - 1;
- *status = fl_string_dynamic_partial_append_nulless(data_make->buffer, range, &arguments->array[arguments->used]);
+ *status = f_string_dynamic_partial_append_nulless(data_make->buffer, range, &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_partial_append_nulless", F_true);
break;
}
}
if (fl_string_dynamic_partial_compare_string(fake_make_parameter_variable_return, data_make->buffer, fake_make_parameter_variable_return_length, iki_content.array[j]) == F_equal_to) {
if (data_make->setting_make.parameter.array[0].value.array[0].used) {
- *status = fl_string_dynamic_append(data_make->setting_make.parameter.array[0].value.array[0], &arguments->array[arguments->used]);
+ *status = f_string_dynamic_append(data_make->setting_make.parameter.array[0].value.array[0], &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_append", F_true);
break;
}
}
else {
- *status = fl_string_append("0", 1, &arguments->array[arguments->used]);
+ *status = f_string_append("0", 1, &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_append", F_true);
break;
}
}
if (fl_string_dynamic_partial_compare_string(reserved_name[k], data_make->buffer, reserved_length[k], iki_content.array[j]) == F_equal_to) {
if (arguments->used >= arguments->size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
return;
}
}
for (l = 0; l < reserved_value[k]->used; l++) {
if (l > 0) {
- *status = fl_string_append(f_string_space_s, 1, &arguments->array[arguments->used]);
+ *status = f_string_append(f_string_space_s, 1, &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_append", F_true);
break;
}
}
- *status = fl_string_dynamic_append(reserved_value[k]->array[l], &arguments->array[arguments->used]);
+ *status = f_string_dynamic_append(reserved_value[k]->array[l], &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_append", F_true);
break;
}
} // for
for (l = 0; l < parameter->array[k].value.used; l++) {
if (l > 0) {
- *status = fl_string_append(f_string_space_s, 1, &arguments->array[arguments->used]);
+ *status = f_string_append(f_string_space_s, 1, &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_append", F_true);
break;
}
}
- *status = fl_string_dynamic_append_nulless(parameter->array[k].value.array[l], &arguments->array[arguments->used]);
+ *status = f_string_dynamic_append_nulless(parameter->array[k].value.array[l], &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
break;
}
} // for
}
else {
if (arguments->used >= arguments->size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamics_increase_by", F_true);
break;
}
}
for (l = 0; l < parameter->array[k].value.used; l++) {
- *status = fl_string_dynamic_append_nulless(parameter->array[k].value.array[l], &arguments->array[arguments->used]);
+ *status = f_string_dynamic_append_nulless(parameter->array[k].value.array[l], &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
break;
}
- *status = fl_string_dynamic_terminate_after(&arguments->array[arguments->used]);
+ *status = f_string_dynamic_terminate_after(&arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_terminate_after", F_true);
// if arguments.used was not incremented, then use the value, otherwise arguments.used is past the value to append to, so subtract 1.
if (used_arguments == arguments->used) {
- *status = fl_string_dynamic_partial_append_nulless(data_make->buffer, range, &arguments->array[arguments->used]);
+ *status = f_string_dynamic_partial_append_nulless(data_make->buffer, range, &arguments->array[arguments->used]);
}
else {
- *status = fl_string_dynamic_partial_append_nulless(data_make->buffer, range, &arguments->array[arguments->used - 1]);
+ *status = f_string_dynamic_partial_append_nulless(data_make->buffer, range, &arguments->array[arguments->used - 1]);
if (F_status_is_error_not(*status)) {
- *status = fl_string_dynamic_terminate_after(&arguments->array[arguments->used - 1]);
+ *status = f_string_dynamic_terminate_after(&arguments->array[arguments->used - 1]);
if (F_status_is_error(*status)) {
fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_terminate_after", F_true);
}
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_partial_append_nulless", F_true);
break;
}
}
}
else {
- *status = fl_string_dynamic_partial_append_nulless(data_make->buffer, content.array[i], &arguments->array[arguments->used]);
+ *status = f_string_dynamic_partial_append_nulless(data_make->buffer, content.array[i], &arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_append_nulless", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_append_nulless", F_true);
break;
}
}
// if iki variable did not match (results in empty string) or iki variable is inside quotes, then increment.
if (used_arguments == arguments->used) {
- *status = fl_string_dynamic_terminate_after(&arguments->array[arguments->used]);
+ *status = f_string_dynamic_terminate_after(&arguments->array[arguments->used]);
if (F_status_is_error(*status)) {
fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_terminate_after", F_true);
unmatched = F_false;
if (bool_value[i]) {
- status = fl_string_append(fake_common_setting_bool_yes, fake_common_setting_bool_yes_length, &value);
+ status = f_string_append(fake_common_setting_bool_yes, fake_common_setting_bool_yes_length, &value);
}
else {
- status = fl_string_append(fake_common_setting_bool_no, fake_common_setting_bool_no_length, &value);
+ status = f_string_append(fake_common_setting_bool_no, fake_common_setting_bool_no_length, &value);
}
break;
if (status == F_equal_to) {
unmatched = F_false;
- status = fl_string_dynamic_append(dynamic_value[i], &value);
+ status = f_string_dynamic_append(dynamic_value[i], &value);
break;
}
} // for
for (f_array_length_t j = 0; j < dynamics_value[i].used; j++) {
- status = fl_string_dynamic_mash(f_string_space_s, 1, dynamics_value[i].array[j], &value);
+ status = f_string_dynamic_mash(f_string_space_s, 1, dynamics_value[i].array[j], &value);
if (F_status_is_error(status)) {
break;
}
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&value);
+ f_string_dynamic_delete(&value);
return status;
}
if (unmatched) {
- fl_string_dynamic_delete(&value);
+ f_string_dynamic_delete(&value);
return F_false;
}
if (quoted) {
- status = fl_string_dynamic_append_nulless(value, &arguments->array[arguments->used]);
+ status = f_string_dynamic_append_nulless(value, &arguments->array[arguments->used]);
}
else {
- status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
+ status = f_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
if (F_status_is_error_not(status)) {
- status = fl_string_dynamic_append_nulless(value, &arguments->array[arguments->used]);
+ status = f_string_dynamic_append_nulless(value, &arguments->array[arguments->used]);
if (F_status_is_error_not(status)) {
- status = fl_string_dynamic_terminate_after(&arguments->array[arguments->used]);
+ status = f_string_dynamic_terminate_after(&arguments->array[arguments->used]);
if (F_status_is_error_not(status)) {
arguments->used++;
}
}
- fl_string_dynamic_delete(&value);
+ f_string_dynamic_delete(&value);
if (F_status_is_error_not(status)) {
return F_true;
{
f_string_dynamic_t name = f_string_dynamic_t_initialize;
- status = fl_string_dynamic_partial_append_nulless(data_make->buffer, range_name, &name);
+ status = f_string_dynamic_partial_append_nulless(data_make->buffer, range_name, &name);
if (F_status_is_error(status)) return status;
status = f_environment_get(name.string, &value);
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
}
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&value);
+ f_string_dynamic_delete(&value);
return status;
}
else if (status == F_exist_not) {
- fl_string_dynamic_delete(&value);
+ f_string_dynamic_delete(&value);
return F_false;
}
if (quoted) {
- status = fl_string_dynamic_append_nulless(value, &arguments->array[arguments->used]);
+ status = f_string_dynamic_append_nulless(value, &arguments->array[arguments->used]);
}
else {
- status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
+ status = f_string_dynamics_increase_by(f_memory_default_allocation_step, arguments);
if (F_status_is_error_not(status)) {
- status = fl_string_dynamic_append_nulless(value, &arguments->array[arguments->used]);
+ status = f_string_dynamic_append_nulless(value, &arguments->array[arguments->used]);
if (F_status_is_error_not(status)) {
- status = fl_string_dynamic_terminate_after(&arguments->array[arguments->used]);
+ status = f_string_dynamic_terminate_after(&arguments->array[arguments->used]);
if (F_status_is_error_not(status)) {
arguments->used++;
}
}
- fl_string_dynamic_delete(&value);
+ f_string_dynamic_delete(&value);
if (F_status_is_error_not(status)) {
return F_true;
if (*status == F_status_set_error(F_signal)) {
for (i = 0; i < section->objects.used; i++) {
- fl_string_dynamics_delete(&arguments[i]);
+ f_string_dynamics_delete(&arguments[i]);
} // for
return 0;
}
for (i = 0; i < section->objects.used; i++) {
- fl_string_dynamics_delete(&arguments[i]);
+ f_string_dynamics_delete(&arguments[i]);
} // for
section_stack->used--;
}
if (operation == fake_make_operation_type_pop) {
- fl_string_dynamic_delete(&data_make->path.stack.array[data_make->path.stack.used - 1]);
+ f_string_dynamic_delete(&data_make->path.stack.array[data_make->path.stack.used - 1]);
data_make->path.stack.used--;
}
else {
if (data_make->path.stack.used == data_make->path.stack.size) {
- *status = fl_string_dynamics_increase_by(f_memory_default_allocation_step, &data_make->path.stack);
+ *status = f_string_dynamics_increase_by(f_memory_default_allocation_step, &data_make->path.stack);
if (F_status_set_fine(*status) == F_array_too_large) {
- fake_print_message_section_operation_path_stack_max(*data, data_make->error, F_array_too_large, "fl_string_dynamics_increase_by", "path stack");
+ fake_print_message_section_operation_path_stack_max(*data, data_make->error, F_array_too_large, "f_string_dynamics_increase_by", "path stack");
return 0;
}
else if (F_status_is_error(*status)) {
// copy the entire real path, including the trailing NULL.
data_make->path_cache.used++;
- fl_string_dynamic_append(data_make->path_cache, &data_make->path.stack.array[data_make->path.stack.used]);
+ f_string_dynamic_append(data_make->path_cache, &data_make->path.stack.array[data_make->path.stack.used]);
if (F_status_is_error(*status)) {
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_append_nulless", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_append_nulless", F_true);
return 0;
}
// clear stack, except for the project root.
for (f_array_length_t i = 1; i < data_make->path.stack.used; i++) {
- fl_string_dynamic_delete(&data_make->path.stack.array[i]);
+ f_string_dynamic_delete(&data_make->path.stack.array[i]);
} // for
data_make->path.stack.used = 1;
if (!return_code) {
if (F_status_is_error(*status)) {
- status2 = fl_string_append("1", 1, &data_make->setting_make.parameter.array[0].value.array[0]);
+ status2 = f_string_append("1", 1, &data_make->setting_make.parameter.array[0].value.array[0]);
}
else {
- status2 = fl_string_append("0", 1, &data_make->setting_make.parameter.array[0].value.array[0]);
+ status2 = f_string_append("0", 1, &data_make->setting_make.parameter.array[0].value.array[0]);
}
return;
fll_error_print(data_make->error, F_status_set_fine(*status), "f_conversion_number_signed_to_string", F_true);
- fl_string_dynamic_delete(&number);
+ f_string_dynamic_delete(&number);
return;
}
- status2 = fl_string_dynamic_append(number, &data_make->setting_make.parameter.array[0].value.array[0]);
+ status2 = f_string_dynamic_append(number, &data_make->setting_make.parameter.array[0].value.array[0]);
- fl_string_dynamic_delete(&number);
+ f_string_dynamic_delete(&number);
}
else {
- status2 = fl_string_append("0", 1, &data_make->setting_make.parameter.array[0].value.array[0]);
+ status2 = f_string_append("0", 1, &data_make->setting_make.parameter.array[0].value.array[0]);
}
}
if (F_status_is_error(status2)) {
*status = status2;
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_append", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_append", F_true);
return;
}
- status2 = fl_string_dynamic_terminate_after(&data_make->setting_make.parameter.array[0].value.array[0]);
+ status2 = f_string_dynamic_terminate_after(&data_make->setting_make.parameter.array[0].value.array[0]);
if (F_status_is_error(status2)) {
*status = status2;
- fll_error_print(data_make->error, F_status_set_fine(*status), "fl_string_dynamic_terminate_after", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(*status), "f_string_dynamic_terminate_after", F_true);
return;
}
for (f_array_length_t i = 0; i < args.size; i++) {
- status = fl_string_dynamic_append(arguments.array[i + 1], &args.array[i]);
+ status = f_string_dynamic_append(arguments.array[i + 1], &args.array[i]);
if (F_status_is_error(status)) {
- fll_error_print(data_make->error, F_status_set_fine(status), "fl_string_dynamic_append", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(status), "f_string_dynamic_append", F_true);
- fl_string_dynamics_delete(&args);
+ f_string_dynamics_delete(&args);
return status;
}
- status = fl_string_dynamic_terminate(&args.array[i]);
+ status = f_string_dynamic_terminate(&args.array[i]);
if (F_status_is_error(status)) {
- fll_error_print(data_make->error, F_status_set_fine(status), "fl_string_dynamic_terminate", F_true);
+ fll_error_print(data_make->error, F_status_set_fine(status), "f_string_dynamic_terminate", F_true);
- fl_string_dynamics_delete(&args);
+ f_string_dynamics_delete(&args);
return status;
}
status = fake_make_operate_process_execute(data, *program, args, as_shell, data_make);
- fl_string_dynamics_delete(&args);
+ f_string_dynamics_delete(&args);
return status;
}
#endif // _di_fake_make_operate_process_run_
range.start = data_make->path.stack.array[0].used + 1;
range.stop = range.start + (path.used - range.start) - 1;
- f_status_t status = fl_string_dynamic_partial_append(path, range, &data_make->path_cache);
+ f_status_t status = f_string_dynamic_partial_append(path, range, &data_make->path_cache);
if (F_status_is_error(status)) return status;
- status = fl_string_dynamic_terminate(&data_make->path_cache);
+ status = f_string_dynamic_terminate(&data_make->path_cache);
if (F_status_is_error(status)) return status;
return status;
}
#define fake_macro_make_parameter_delete_simple(parameter) \
- fl_string_dynamics_delete(¶meter.build); \
- fl_string_dynamics_delete(¶meter.color); \
- fl_string_dynamics_delete(¶meter.data); \
- fl_string_dynamics_delete(¶meter.define); \
- fl_string_dynamics_delete(¶meter.fakefile); \
- fl_string_dynamics_delete(¶meter.mode); \
- fl_string_dynamics_delete(¶meter.process); \
- fl_string_dynamics_delete(¶meter.settings); \
- fl_string_dynamics_delete(¶meter.sources); \
- fl_string_dynamics_delete(¶meter.verbosity); \
- fl_string_dynamics_delete(¶meter.work);
+ f_string_dynamics_delete(¶meter.build); \
+ f_string_dynamics_delete(¶meter.color); \
+ f_string_dynamics_delete(¶meter.data); \
+ f_string_dynamics_delete(¶meter.define); \
+ f_string_dynamics_delete(¶meter.fakefile); \
+ f_string_dynamics_delete(¶meter.mode); \
+ f_string_dynamics_delete(¶meter.process); \
+ f_string_dynamics_delete(¶meter.settings); \
+ f_string_dynamics_delete(¶meter.sources); \
+ f_string_dynamics_delete(¶meter.verbosity); \
+ f_string_dynamics_delete(¶meter.work);
#endif // _di_fake_make_parameter_t_
#ifndef _di_fake_make_path_t_
}
#define fake_macro_make_path_delete_simple(path) \
- fl_string_dynamics_delete(&path.stack);
+ f_string_dynamics_delete(&path.stack);
#endif // _di_fake_make_path_t_
#ifndef _di_fake_make_data_t_
#define fake_macro_make_data_t_delete_simple(data) \
fake_macro_build_setting_t_delete_simple(data.setting_build) \
fake_macro_make_setting_t_delete_simple(data.setting_make) \
- fl_string_maps_delete(&data.environment); \
+ f_string_maps_delete(&data.environment); \
fake_macro_make_parameter_delete_simple(data.parameter) \
fake_macro_make_path_delete_simple(data.path) \
f_macro_fss_nameds_t_delete_simple(data.fakefile) \
- fl_string_dynamic_delete(&data.buffer); \
- fl_string_dynamic_delete(&data.path_cache);
+ f_string_dynamic_delete(&data.buffer); \
+ f_string_dynamic_delete(&data.path_cache);
#endif // _di_fake_make_data_t_
/**
}
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&file_data_build_process_post);
- fl_string_dynamic_delete(&file_data_build_process_pre);
+ f_string_dynamic_delete(&file_data_build_process_post);
+ f_string_dynamic_delete(&file_data_build_process_pre);
return status;
}
parameters.array[5].used = 0;
parameters.array[6].used = 0;
- fl_string_dynamics_delete(& parameters);
+ f_string_dynamics_delete(& parameters);
firewall_delete_local_data(&local);
firewall_delete_data(data);
return status;
status = firewall_buffer_rules(file_path.string, F_true, &local, data);
- fl_string_dynamic_delete(&file_path);
+ f_string_dynamic_delete(&file_path);
}
if (F_status_is_error(status)) {
f_macro_string_lengths_t_delete_simple(data->parameters[i].values);
} // for
- fl_string_dynamics_delete(&data->chains);
+ f_string_dynamics_delete(&data->chains);
f_macro_string_lengths_t_delete_simple(data->remaining);
- fl_string_dynamics_delete(&data->devices);
+ f_string_dynamics_delete(&data->devices);
f_macro_color_context_t_delete_simple(data->context);
f_macro_string_dynamic_t_new(status, device, data.devices.array[local.device].used);
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&device);
+ f_string_dynamic_delete(&device);
return status;
}
is_ip_list = F_false;
ip_list_direction = F_false;
- fl_string_dynamic_delete(&ip_list);
+ f_string_dynamic_delete(&ip_list);
// process chain rule
if (length >= firewall_chain_length && fl_string_compare(local.buffer.string + local.rule_objects.array[i].start, (f_string_t) firewall_chain, length, firewall_chain_length) == F_equal_to) {
invalid = F_true;
}
else if (length >= firewall_device_all_length && fl_string_compare(local.buffer.string + local.rule_contents.array[i].array[0].start, (f_string_t) firewall_device_all, length, firewall_device_all_length) == F_equal_to) {
- fl_string_dynamic_delete(&device);
+ f_string_dynamic_delete(&device);
device_all = F_true;
continue;
}
device.used = data.devices.array[local.device].used;
}
else {
- fl_string_dynamic_delete(&device);
+ f_string_dynamic_delete(&device);
}
device_all = F_false;
device.used = length;
}
else {
- fl_string_dynamic_delete(&device);
+ f_string_dynamic_delete(&device);
}
device_all = F_false;
use_protocol = F_false;
}
else if (length > 0) {
- fl_string_dynamic_delete(&protocol);
+ f_string_dynamic_delete(&protocol);
f_macro_string_dynamic_t_new(status, protocol, length);
if (F_status_is_error(status)) break;
for (r = repeat; r > 0; r--) {
// first add the program name
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
f_macro_string_dynamics_new(status, arguments, firewall_default_allocation_step);
if (F_status_is_error(status)) break;
}
}
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
if (F_status_is_error(status)) break;
if (argument.used > 0) {
firewall_macro_append_argument_to_arguments(status, arguments, argument)
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&argument);
+ f_string_dynamic_delete(&argument);
break;
}
if (F_status_is_error(status)) {
fl_color_print(data.error.to.stream, data.context.set.error, "%sUnable to allocate memory.%c", fll_error_print_error, f_string_eol_s[0]);
- fl_string_dynamic_delete(&ip_list_action);
+ f_string_dynamic_delete(&ip_list_action);
}
else {
f_string_dynamic_t ip_argument = f_string_dynamic_t_initialize;
firewall_macro_append_argument_to_arguments(status, arguments, ip_list_action)
if (F_status_is_error(status)) {
- fl_string_dynamic_delete(&ip_argument);
+ f_string_dynamic_delete(&ip_argument);
break;
}
fprintf(f_type_error, "\n");
// remove ip_argument from arguments string.
- fl_string_dynamic_delete(&arguments.array[arguments.used]);
+ f_string_dynamic_delete(&arguments.array[arguments.used]);
arguments.used--;
break;
fl_color_print(data.error.to.stream, data.context.set.error, "%sInvalid parameter when calling fll_execute_program()%c", fll_error_print_error, f_string_eol_s[0]);
// remove ip_argument from arguments string.
- fl_string_dynamic_delete(&arguments.array[arguments.used]);
+ f_string_dynamic_delete(&arguments.array[arguments.used]);
arguments.used--;
break;
}
// remove ip_argument from arguments string.
- fl_string_dynamic_delete(&arguments.array[arguments.used]);
+ f_string_dynamic_delete(&arguments.array[arguments.used]);
arguments.used--;
} // for
- fl_string_dynamic_delete(&ip_argument);
+ f_string_dynamic_delete(&ip_argument);
// remove ip_list_action from arguments string.
- fl_string_dynamic_delete(&arguments.array[arguments.used]);
+ f_string_dynamic_delete(&arguments.array[arguments.used]);
arguments.used--;
}
}
}
}
- fl_string_dynamic_delete(&local_buffer);
- fl_string_dynamic_delete(&file_path);
+ f_string_dynamic_delete(&local_buffer);
+ f_string_dynamic_delete(&file_path);
f_macro_fss_objects_t_delete_simple(basic_objects);
f_macro_fss_contents_t_delete_simple(basic_contents);
} // for
} // for
- fl_string_dynamic_delete(&ip_list);
- fl_string_dynamic_delete(&argument);
- fl_string_dynamics_delete(&arguments);
- fl_string_dynamic_delete(&device);
- fl_string_dynamic_delete(&protocol);
+ f_string_dynamic_delete(&ip_list);
+ f_string_dynamic_delete(&argument);
+ f_string_dynamics_delete(&arguments);
+ f_string_dynamic_delete(&device);
+ f_string_dynamic_delete(&protocol);
return status;
}
f_macro_string_dynamic_t_new(status, arguments.array[0], firewall_chain_create_command_length);
if (F_status_is_error(status)) {
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return status;
}
if (F_status_is_error(status)) {
arguments.used = 1;
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return status;
}
f_macro_string_dynamics_t_resize(status, data->chains, data->chains.used + firewall_default_allocation_step);
if (F_status_is_error(status)) {
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return status;
}
f_macro_string_dynamic_t_resize(status, arguments.array[1], length);
if (F_status_is_error(status)) {
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return status;
}
f_macro_string_dynamic_t_new(status, data->chains.array[data->chains.used], length);
if (F_status_is_error(status)) {
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return status;
}
fl_color_print(data->error.to.stream, data->context.set.error, "%sAn unhandled error (%u) has occurred while calling fll_execute_program()%c", fll_error_print_error, status, f_string_eol_s[0]);
}
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return status;
}
}
i++;
} // while
- fl_string_dynamics_delete(&arguments);
+ f_string_dynamics_delete(&arguments);
return status;
}
local->device = 0;
local->chain = 0;
- fl_string_dynamic_delete(&local->buffer);
+ f_string_dynamic_delete(&local->buffer);
f_macro_array_lengths_t_delete_simple(local->chain_ids);
f_macro_fss_objects_t_delete_simple(local->chain_objects);
f_macro_fss_contents_t_delete_simple(local->chain_contents);
}
#define firewall_macro_delete_fss_buffers(status, buffer, objects, contents) \
- fl_string_dynamic_delete(&buffer); \
+ f_string_dynamic_delete(&buffer); \
f_macro_fss_objects_t_delete(status, objects); \
f_macro_fss_contents_t_delete(status, contents);
// Clear buffers before continuing.
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
if (F_status_is_error_not(status) && data->remaining.used > 0) {
// Clear buffers before repeating the loop.
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
} // for
if (F_status_is_error(status)) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
}
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
f_macro_string_lengths_t_delete_simple(data->remaining);
f_macro_color_context_t_delete_simple(data->context);
status = fl_string_rip(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
}
else {
- status = fl_string_append(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
+ status = f_string_append(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
}
if (F_status_is_error(status)) {
fl_color_print(data.error.to.stream, data.context.set.error, "' because the maximum buffer size was reached.%c", f_string_eol_s[0]);
}
else {
- f_string_t function = "fl_string_append";
+ f_string_t function = "f_string_append";
if (data.parameters[fss_basic_list_read_parameter_trim].result == f_console_result_found) {
function = "fl_string_rip";
else if (status == F_data_not_stop || status == F_data_not_eos) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
if (data->parameters[fss_basic_list_read_parameter_total].result == f_console_result_found) {
fprintf(data->output.stream, "0%c", f_string_eol_s[0]);
if (F_status_is_error(status)) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
return status;
}
structure.value_at = 0; \
f_macro_string_dynamic_t_clear(structure.value_name)
- #define fss_basic_list_read_macro_depth_t_delete(status, structure) status = fl_string_dynamic_delete(&structure.value_name);
- #define fss_basic_list_read_macro_depth_t_delete_simple(structure) fl_string_dynamic_delete(&structure.value_name);
+ #define fss_basic_list_read_macro_depth_t_delete(status, structure) status = f_string_dynamic_delete(&structure.value_name);
+ #define fss_basic_list_read_macro_depth_t_delete_simple(structure) f_string_dynamic_delete(&structure.value_name);
#endif // _di_fss_basic_list_read_depth_t_
/**
}
}
- fl_string_dynamic_delete(&escaped);
+ f_string_dynamic_delete(&escaped);
// object and content, though being a "dynamic" type, is being used statically, so clear them up to avoid invalid free().
object.string = 0;
}
}
- fl_string_dynamic_delete(&buffer);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&buffer);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
fss_basic_list_write_delete_data(data);
return status;
}
}
if (!object || !content) {
- status = fl_string_append(f_string_eol, 1, buffer);
+ status = f_string_append(f_string_eol, 1, buffer);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
}
}
if (object.used + block.used > object.size) {
- status = fl_string_dynamic_increase_by(block.used, &object);
+ status = f_string_dynamic_increase_by(block.used, &object);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
if (total) {
if (content.used + total > content.size) {
- status = fl_string_dynamic_increase_by(total, &content);
+ status = f_string_dynamic_increase_by(total, &content);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
status = fss_basic_list_write_process(data, output, quote, &object, &content, buffer);
}
- fl_string_dynamic_delete(&block);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&block);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
return status;
}
#endif // _di_fss_basic_list_write_process_pipe_
// Clear buffers before continuing.
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
if (F_status_is_error_not(status) && data->remaining.used > 0) {
// Clear buffers before repeating the loop.
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
} // for
if (F_status_is_error(status)) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
}
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
f_macro_string_lengths_t_delete_simple(data->remaining);
f_macro_color_context_t_delete_simple(data->context);
status = fl_string_rip(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
}
else {
- status = fl_string_append(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
+ status = f_string_append(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
}
if (F_status_is_error(status)) {
fl_color_print(data.error.to.stream, data.context.set.error, "' because the maximum buffer size was reached.%c", f_string_eol_s[0]);
}
else {
- f_string_t function = "fl_string_append";
+ f_string_t function = "f_string_append";
if (data.parameters[fss_basic_read_parameter_trim].result == f_console_result_found) {
function = "fl_string_rip";
else if (status == F_data_not_stop || status == F_data_not_eos) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
if (data->parameters[fss_basic_read_parameter_total].result == f_console_result_found) {
fprintf(data->output.stream, "0%c", f_string_eol_s[0]);
if (F_status_is_error(status)) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
return status;
}
structure.value_at = 0; \
f_macro_string_dynamic_t_clear(structure.value_name)
- #define fss_basic_read_macro_depth_t_delete(status, structure) status = fl_string_dynamic_delete(&structure.value_name);
- #define fss_basic_read_macro_depth_t_delete_simple(structure) fl_string_dynamic_delete(&structure.value_name);
+ #define fss_basic_read_macro_depth_t_delete(status, structure) status = f_string_dynamic_delete(&structure.value_name);
+ #define fss_basic_read_macro_depth_t_delete_simple(structure) f_string_dynamic_delete(&structure.value_name);
#endif // _di_fss_basic_read_depth_t_
/**
}
}
- fl_string_dynamic_delete(&escaped);
+ f_string_dynamic_delete(&escaped);
// object and content, though being a "dynamic" type, is being used statically, so clear them up to avoid invalid free().
object.string = 0;
}
}
- fl_string_dynamic_delete(&buffer);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&buffer);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
fss_basic_write_delete_data(data);
return status;
}
}
if (!object || !content) {
- status = fl_string_append(f_string_eol, 1, buffer);
+ status = f_string_append(f_string_eol, 1, buffer);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
}
}
if (object.used + block.used > object.size) {
- status = fl_string_dynamic_increase_by(block.used, &object);
+ status = f_string_dynamic_increase_by(block.used, &object);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
if (total) {
if (content.used + total > content.size) {
- status = fl_string_dynamic_increase_by(total, &content);
+ status = f_string_dynamic_increase_by(total, &content);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
status = fss_basic_write_process(data, output, quote, &object, &content, buffer);
}
- fl_string_dynamic_delete(&block);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&block);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
return status;
}
#endif // _di_fss_basic_write_process_pipe_
// Clear buffers before continuing.
f_macro_fss_nest_t_delete_simple(data->nest);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
if (F_status_is_error_not(status) && data->remaining.used > 0) {
// Clear buffers before repeating the loop.
f_macro_fss_nest_t_delete_simple(data->nest);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
} // for
if (F_status_is_error(status)) {
f_macro_fss_nest_t_delete_simple(data->nest);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
}
f_macro_fss_nest_t_delete_simple(data->nest);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
f_macro_string_lengths_t_delete_simple(data->remaining);
f_macro_color_context_t_delete_simple(data->context);
}
}
else {
- status = fl_string_append(arguments.argv[values_order[i]], strnlen(arguments.argv[values_order[i]], f_console_length_size), &depths->array[depths->used].value_name);
+ status = f_string_append(arguments.argv[values_order[i]], strnlen(arguments.argv[values_order[i]], f_console_length_size), &depths->array[depths->used].value_name);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
}
}
else if (status == F_data_not_stop || status == F_data_not_eos) {
f_macro_fss_nest_t_delete_simple(data->nest);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
if (data->parameters[fss_embedded_list_read_parameter_total].result == f_console_result_found) {
fprintf(data->output.stream, "0%c", f_string_eol_s[0]);
if (F_status_is_error(status)) {
f_macro_fss_nest_t_delete_simple(data->nest);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
return status;
}
structure.value_at = 0; \
f_macro_string_dynamic_t_clear(structure.value_name)
- #define fss_embedded_list_read_macro_depth_t_delete(status, structure) status = fl_string_dynamic_delete(&structure.value_name)
- #define fss_embedded_list_read_macro_depth_t_delete_simple(structure) fl_string_dynamic_delete(&structure.value_name)
+ #define fss_embedded_list_read_macro_depth_t_delete(status, structure) status = f_string_dynamic_delete(&structure.value_name)
+ #define fss_embedded_list_read_macro_depth_t_delete_simple(structure) f_string_dynamic_delete(&structure.value_name)
#endif // _di_fss_embedded_list_read_depth_t_
/**
}
}
- fl_string_dynamic_delete(&escaped);
+ f_string_dynamic_delete(&escaped);
f_macro_string_ranges_t_delete_simple(ignore);
// object and content, though being a "dynamic" type, is being used statically, so clear them up to avoid invalid free().
}
}
- fl_string_dynamic_delete(&buffer);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&buffer);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
fss_embedded_list_write_delete_data(data);
return status;
}
}
if (!object || !content) {
- status = fl_string_append(f_string_eol, 1, buffer);
+ status = f_string_append(f_string_eol, 1, buffer);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
}
}
if (object.used + block.used > object.size) {
- status = fl_string_dynamic_increase_by(block.used, &object);
+ status = f_string_dynamic_increase_by(block.used, &object);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
if (total) {
if (content.used + total > content.size) {
- status = fl_string_dynamic_increase_by(total, &content);
+ status = f_string_dynamic_increase_by(total, &content);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
status = fss_embedded_list_write_process(data, output, quote, &object, &content, ignore, buffer);
}
- fl_string_dynamic_delete(&block);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&block);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
return status;
}
#endif // _di_fss_embedded_list_write_process_pipe_
// Clear buffers before continuing.
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
if (F_status_is_error_not(status) && data->remaining.used > 0) {
// Clear buffers before repeating the loop.
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
} // for
if (F_status_is_error(status)) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
}
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
f_macro_string_lengths_t_delete_simple(data->remaining);
f_macro_color_context_t_delete_simple(data->context);
status = fl_string_rip(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
}
else {
- status = fl_string_append(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
+ status = f_string_append(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
}
if (F_status_is_error(status)) {
fl_color_print(data.error.to.stream, data.context.set.error, "' because the maximum buffer size was reached.%c", f_string_eol_s[0]);
}
else {
- f_string_t function = "fl_string_append";
+ f_string_t function = "f_string_append";
if (data.parameters[fss_extended_list_read_parameter_trim].result == f_console_result_found) {
function = "fl_string_rip";
else if (status == F_data_not_stop || status == F_data_not_eos) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
if (data->parameters[fss_extended_list_read_parameter_total].result == f_console_result_found) {
fprintf(data->output.stream, "0%c", f_string_eol_s[0]);
if (F_status_is_error(status)) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
return status;
}
structure.value_at = 0; \
f_macro_string_dynamic_t_clear(structure.value_name)
- #define fss_extended_list_read_macro_depth_t_delete(status, structure) status = fl_string_dynamic_delete(&structure.value_name)
- #define fss_extended_list_read_macro_depth_t_delete_simple(structure) fl_string_dynamic_delete(&structure.value_name)
+ #define fss_extended_list_read_macro_depth_t_delete(status, structure) status = f_string_dynamic_delete(&structure.value_name)
+ #define fss_extended_list_read_macro_depth_t_delete_simple(structure) f_string_dynamic_delete(&structure.value_name)
#endif // _di_fss_extended_list_read_depth_t_
/**
}
}
- fl_string_dynamic_delete(&escaped);
+ f_string_dynamic_delete(&escaped);
f_macro_string_ranges_t_delete_simple(ignore);
// object and content, though being a "dynamic" type, is being used statically, so clear them up to avoid invalid free().
}
}
- fl_string_dynamic_delete(&buffer);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&buffer);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
fss_extended_list_write_delete_data(data);
return status;
}
}
if (!object || !content) {
- status = fl_string_append(f_string_eol, 1, buffer);
+ status = f_string_append(f_string_eol, 1, buffer);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
}
}
if (object.used + block.used > object.size) {
- status = fl_string_dynamic_increase_by(block.used, &object);
+ status = f_string_dynamic_increase_by(block.used, &object);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
if (total) {
if (content.used + total > content.size) {
- status = fl_string_dynamic_increase_by(total, &content);
+ status = f_string_dynamic_increase_by(total, &content);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
status = fss_extended_list_write_process(data, output, quote, &object, &content, ignore, buffer);
}
- fl_string_dynamic_delete(&block);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&block);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
return status;
}
#endif // _di_fss_extended_list_write_process_pipe_
// Clear buffers before continuing.
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
if (F_status_is_error_not(status) && data->remaining.used > 0) {
// Clear buffers before repeating the loop.
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
} // for
if (F_status_is_error(status)) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
}
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
f_macro_string_lengths_t_delete_simple(data->remaining);
f_macro_color_context_t_delete_simple(data->context);
status = fl_string_rip(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
}
else {
- status = fl_string_append(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
+ status = f_string_append(arguments.argv[depths->array[i].index_name], strlen(arguments.argv[depths->array[i].index_name]), &depths->array[i].value_name);
}
if (F_status_is_error(status)) {
fl_color_print(data.error.to.stream, data.context.set.error, "' because the maximum buffer size was reached.%c", f_string_eol_s[0]);
}
else {
- f_string_t function = "fl_string_append";
+ f_string_t function = "f_string_append";
if (data.parameters[fss_extended_read_parameter_trim].result == f_console_result_found) {
function = "fl_string_rip";
else if (status == F_data_not_stop || status == F_data_not_eos) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
if (data->parameters[fss_extended_read_parameter_total].result == f_console_result_found) {
fprintf(data->output.stream, "0%c", f_string_eol_s[0]);
if (F_status_is_error(status)) {
f_macro_fss_contents_t_delete_simple(data->contents);
f_macro_fss_objects_t_delete_simple(data->objects);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
return status;
}
structure.value_at = 0; \
f_macro_string_dynamic_t_clear(structure.value_name)
- #define fss_extended_read_macro_depth_t_delete(status, structure) status = fl_string_dynamic_delete(&structure.value_name)
- #define fss_extended_read_macro_depth_t_delete_simple(structure) fl_string_dynamic_delete(&structure.value_name)
+ #define fss_extended_read_macro_depth_t_delete(status, structure) status = f_string_dynamic_delete(&structure.value_name)
+ #define fss_extended_read_macro_depth_t_delete_simple(structure) f_string_dynamic_delete(&structure.value_name)
#endif // _di_fss_extended_read_depth_t_
/**
else {
object.used = 0;
- status = fl_string_dynamics_increase_by(data->parameters[fss_extended_write_parameter_content].values.used, &contents);
+ status = f_string_dynamics_increase_by(data->parameters[fss_extended_write_parameter_content].values.used, &contents);
if (status == F_array_too_large) {
status = F_status_set_error(status);
}
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_dynamics_increase_by", F_true);
}
else {
f_array_length_t i = 0;
if (content_current < object_current || content_current > object_next) break;
}
- status = fl_string_dynamics_increase_by(f_fss_default_allocation_step, &contents);
+ status = f_string_dynamics_increase_by(f_fss_default_allocation_step, &contents);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_dynamics_increase_by", F_true);
break;
}
contents.array[contents.used].used = 0;
}
- status = fl_string_append(arguments.argv[data->parameters[fss_extended_write_parameter_content].values.array[j]], strnlen(arguments.argv[data->parameters[fss_extended_write_parameter_content].values.array[j]], f_console_length_size), &contents.array[contents.used]);
+ status = f_string_append(arguments.argv[data->parameters[fss_extended_write_parameter_content].values.array[j]], strnlen(arguments.argv[data->parameters[fss_extended_write_parameter_content].values.array[j]], f_console_length_size), &contents.array[contents.used]);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append", F_true);
break;
}
}
}
- fl_string_dynamic_delete(&escaped);
+ f_string_dynamic_delete(&escaped);
// object, though being a "dynamic" type, is being used statically, so clear them up to avoid invalid free().
object.string = 0;
}
}
- fl_string_dynamic_delete(&buffer);
- fl_string_dynamic_delete(&object);
- fl_string_dynamics_delete(&contents);
+ f_string_dynamic_delete(&buffer);
+ f_string_dynamic_delete(&object);
+ f_string_dynamics_delete(&contents);
fss_extended_write_delete_data(data);
return status;
}
}
}
else if (!object) {
- status = fl_string_append(f_string_eol, 1, buffer);
+ status = f_string_append(f_string_eol, 1, buffer);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_append", F_true);
return status;
}
}
}
if (object.used + block.used > object.size) {
- status = fl_string_dynamic_increase_by(block.used, &object);
+ status = f_string_dynamic_increase_by(block.used, &object);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
if (state == 0x2) {
if (contents.used + 1 > contents.size) {
- status = fl_string_dynamics_increase_by(f_fss_default_allocation_step, &contents);
+ status = f_string_dynamics_increase_by(f_fss_default_allocation_step, &contents);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase_by", F_true);
break;
}
}
if (block.string[range.start] == fss_extended_write_pipe_content_start) {
if (contents.used + 1 > contents.size) {
- status = fl_string_dynamics_increase_by(f_fss_default_allocation_step, &contents);
+ status = f_string_dynamics_increase_by(f_fss_default_allocation_step, &contents);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamics_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamics_increase_by", F_true);
break;
}
}
}
if (contents.array[contents.used - 1].used + 1 > contents.array[contents.used - 1].size) {
- status = fl_string_dynamic_increase_by(f_fss_default_allocation_step, &contents.array[contents.used - 1]);
+ status = f_string_dynamic_increase_by(f_fss_default_allocation_step, &contents.array[contents.used - 1]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_increase_by", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_increase_by", F_true);
break;
}
}
status = fss_extended_write_process(data, output, quote, &object, &contents, buffer);
}
- fl_string_dynamic_delete(&block);
- fl_string_dynamic_delete(&object);
- fl_string_dynamics_delete(&contents);
+ f_string_dynamic_delete(&block);
+ f_string_dynamic_delete(&object);
+ f_string_dynamics_delete(&contents);
return status;
}
#endif // _di_fss_extended_write_process_pipe_
}
// Clear buffers before continuing.
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
}
if (F_status_is_fine(status) && data->remaining.used > 0) {
if (F_status_is_error(status)) break;
// Clear buffers before repeating the loop.
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
} // for
}
}
} // for
f_macro_string_lengths_t_delete_simple(data->remaining);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
f_macro_color_context_t_delete_simple(data->context);
index = data->parameters[iki_read_parameter_name].values.array[i];
name.used = 0;
- status = fl_string_append_nulless(arguments.argv[index], strlen(arguments.argv[index]), &name);
+ status = f_string_append_nulless(arguments.argv[index], strlen(arguments.argv[index]), &name);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append_nulless", F_true);
for (f_array_length_t i = 0; i < variable->used; i++) {
iki_read_macro_substitutions_t_delete_simple(substitutionss[i]);
} // for
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
} // for
} // for
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
if (unmatched) status = F_data_not;
else status = F_none;
break;
}
- status = fl_string_append_nulless(arguments.argv[index], length_argument, &names.array[names.used]);
+ status = f_string_append_nulless(arguments.argv[index], length_argument, &names.array[names.used]);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append_nulless", F_true);
break;
}
iki_read_macro_substitutions_t_delete_simple(substitutionss[i]);
} // for
- fl_string_dynamics_delete(&names);
+ f_string_dynamics_delete(&names);
return status;
}
}
iki_read_macro_substitutions_t_delete_simple(substitutionss[i]);
} // for
- fl_string_dynamics_delete(&names);
+ f_string_dynamics_delete(&names);
return F_none;
}
#endif // _di_iki_read_process_buffer_ranges_whole_
index = data->parameters[iki_read_parameter_name].values.array[i];
name.used = 0;
- status = fl_string_append_nulless(arguments.argv[index], strlen(arguments.argv[index]), &name);
+ status = f_string_append_nulless(arguments.argv[index], strlen(arguments.argv[index]), &name);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_append_nulless", F_true);
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
return status;
}
} // for
} // for
- fl_string_dynamic_delete(&name);
+ f_string_dynamic_delete(&name);
}
else {
total = variable->used;
content.used = 0;
if (buffer.used) {
- status = fl_string_dynamic_partial_append_nulless(buffer, range, &content);
+ status = f_string_dynamic_partial_append_nulless(buffer, range, &content);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
break;
}
}
else {
object.used = 0;
- status = fl_string_dynamic_partial_append_nulless(buffer, range, &object);
+ status = f_string_dynamic_partial_append_nulless(buffer, range, &object);
if (F_status_is_error(status)) {
- fll_error_print(data->error, F_status_set_fine(status), "fl_string_dynamic_partial_append_nulless", F_true);
+ fll_error_print(data->error, F_status_set_fine(status), "f_string_dynamic_partial_append_nulless", F_true);
break;
}
status = F_status_set_error(F_parameter);
}
- fl_string_dynamic_delete(&buffer);
- fl_string_dynamic_delete(&object);
- fl_string_dynamic_delete(&content);
+ f_string_dynamic_delete(&buffer);
+ f_string_dynamic_delete(&object);
+ f_string_dynamic_delete(&content);
}
if (F_status_is_error_not(status)) {
}
}
- fl_string_dynamic_delete(&escaped);
+ f_string_dynamic_delete(&escaped);
}
if (data->parameters[iki_write_parameter_file].result == f_console_result_additional) {
} // for
f_macro_string_lengths_t_delete_simple(data->remaining);
- fl_string_dynamic_delete(&data->buffer);
+ f_string_dynamic_delete(&data->buffer);
f_macro_color_context_t_delete_simple(data->context);
if (F_status_is_error(status)) {
fll_error_print(data.error, F_status_set_fine(status), "fll_iki_content_escape", F_true);
- fl_string_dynamic_delete(&(*escaped));
+ f_string_dynamic_delete(&(*escaped));
return F_status_set_error(F_failure);
}
f_macro_string_lengths_t_delete_simple(data->remaining);
- fl_string_dynamic_delete(&data->setting_kernel.root);
- fl_string_dynamic_delete(&data->setting_kernel.root_group);
- fl_string_dynamic_delete(&data->setting_kernel.root_sub);
- fl_string_dynamic_delete(&data->setting_kernel.run);
- fl_string_dynamic_delete(&data->setting_kernel.settings);
- fl_string_dynamic_delete(&data->setting_kernel.settings_name);
+ f_string_dynamic_delete(&data->setting_kernel.root);
+ f_string_dynamic_delete(&data->setting_kernel.root_group);
+ f_string_dynamic_delete(&data->setting_kernel.root_sub);
+ f_string_dynamic_delete(&data->setting_kernel.run);
+ f_string_dynamic_delete(&data->setting_kernel.settings);
+ f_string_dynamic_delete(&data->setting_kernel.settings_name);
f_macro_color_context_t_delete_simple(data->context);
parameter_value[j]->used = 0;
if (content.array[j].start <= content.array[j].stop) {
- status = fl_string_dynamic_partial_append(buffer, content.array[j], parameter_value[j]);
+ status = f_string_dynamic_partial_append(buffer, content.array[j], parameter_value[j]);
if (F_status_is_error(status)) {
- fll_error_print(data.error, F_status_set_fine(status), "fl_string_dynamic_partial_append", F_true);
+ fll_error_print(data.error, F_status_set_fine(status), "f_string_dynamic_partial_append", F_true);
i = variable.used;
break;
f_macro_iki_variable_t_delete_simple(variable);
f_macro_iki_vocabulary_t_delete_simple(vocabulary);
f_macro_iki_content_t_delete_simple(content);
- fl_string_dynamic_delete(&cache);
+ f_string_dynamic_delete(&cache);
}
f_file_stream_close(F_true, &command_line);
- fl_string_dynamic_delete(&buffer);
+ f_string_dynamic_delete(&buffer);
return status;
}