From: Kevin Day Date: Wed, 7 Dec 2022 03:20:29 +0000 (-0600) Subject: Bugfix: Incorrect ifndef defines for some functions and structures. X-Git-Url: https://git.kevux.org/?a=commitdiff_plain;h=fe22caee340a27d46d455929030b794fc4335f79;p=fll Bugfix: Incorrect ifndef defines for some functions and structures. The _di_string_ascii_s_ is incorrect and should instead be _di_f_string_ascii_s_. These have been exposed while building the stand alone which is very sensitive to the defines. --- diff --git a/level_0/f_file/c/private-file.c b/level_0/f_file/c/private-file.c index 314af28..fa01bb6 100644 --- a/level_0/f_file/c/private-file.c +++ b/level_0/f_file/c/private-file.c @@ -680,7 +680,7 @@ extern "C" { } #endif // !defined(_di_f_file_role_change_at_) || !defined(_di_f_file_copy_at_) -#if !defined(_di_f_file_stat_) || !defined(_di_f_file_copy_) +#if !defined(_di_f_file_stat_) || !defined(_di_f_file_copy_) || !defined(_di_f_file_exists_) || !defined(_di_f_file_is_) || !defined(_di_f_file_touch_) f_status_t private_f_file_stat(const f_string_static_t path, const bool dereference, struct stat * const file_stat) { if ((dereference ? stat(path.string, file_stat) : lstat(path.string, file_stat)) < 0) { @@ -699,9 +699,9 @@ extern "C" { return F_none; } -#endif // !defined(_di_f_file_stat_) || !defined(_di_f_file_copy_) +#endif // !defined(_di_f_file_stat_) || !defined(_di_f_file_copy_) || !defined(_di_f_file_exists_) || !defined(_di_f_file_is_) || !defined(_di_f_file_touch_) -#if !defined(_di_f_file_stat_at_) || !defined(_di_f_file_copy_at_) +#if !defined(_di_f_file_stat_at_) || !defined(_di_f_file_exists_at_) || !defined(_di_f_file_copy_at_) f_status_t private_f_file_stat_at(const f_file_t file, const f_string_static_t path, const int flag, struct stat * const file_stat) { if (fstatat(file.id, path.string, file_stat, flag) < 0) { @@ -721,7 +721,7 @@ extern "C" { return F_none; } -#endif // !defined(_di_f_file_stat_at_) || !defined(_di_f_file_copy_at_) +#endif // !defined(_di_f_file_stat_at_) || !defined(_di_f_file_exists_at_) || !defined(_di_f_file_touch_at_) #if !defined(_di_f_file_stat_by_id_) || !defined(_di_f_file_size_by_id_) f_status_t private_f_file_stat_by_id(const f_file_t file, struct stat * const file_stat) { diff --git a/level_0/f_string/c/string/static.h b/level_0/f_string/c/string/static.h index 5b03504..a6d1808 100644 --- a/level_0/f_string/c/string/static.h +++ b/level_0/f_string/c/string/static.h @@ -96,7 +96,7 @@ extern "C" { * The NULL ASCII string can be represented by the integer 0; however, given that these are all NULL-terminated strings the NULL character is represented with a NULL termination as well. * The NULL ASCII string therefore has two NULLs, first the NULL represents the NULL and the second represents the NULL termination. */ -#ifndef _di_string_ascii_s_ +#ifndef _di_f_string_ascii_s_ #define F_string_ascii_0_s "0" #define F_string_ascii_1_s "1" #define F_string_ascii_2_s "2" @@ -492,7 +492,7 @@ extern "C" { extern const f_string_static_t f_string_ascii_text_stop_s; extern const f_string_static_t f_string_ascii_transmission_stop_s; extern const f_string_static_t f_string_ascii_transmission_block_end_s; -#endif // _di_string_ascii_s_ +#endif // _di_f_string_ascii_s_ /** * Define the end of line character. diff --git a/level_0/f_utf/c/utf/private-dynamics.c b/level_0/f_utf/c/utf/private-dynamics.c index 612342f..6c8c1ae 100644 --- a/level_0/f_utf/c/utf/private-dynamics.c +++ b/level_0/f_utf/c/utf/private-dynamics.c @@ -84,7 +84,7 @@ extern "C" { } #endif // !defined(_di_f_utf_string_dynamics_append_all_) || !defined(_di_f_utf_string_map_multis_append_) || !defined(_di_f_utf_string_map_multis_append_all_) -#if !defined(_di_f_utf_string_dynamics_decrease_by_) || !defined(_di_f_utf_string_dynamics_increase_) || !defined(_di_f_utf_string_dynamics_increase_by_) || !defined(_di_f_utf_string_map_multis_append_) +#if !defined(_di_f_utf_string_dynamics_decrease_by_) || !defined(_di_f_utf_string_dynamics_increase_) || !defined(_di_f_utf_string_dynamics_increase_by_) || !defined(_di_f_utf_string_map_multis_append_) || !defined(_di_f_utf_string_map_multis_decrease_by_) || !defined(_di_f_utf_string_map_multis_increase_) || !defined(_di_f_utf_string_map_multis_increase_by_) || !defined(_di_f_utf_string_map_multis_terminate_) || !defined(_di_f_utf_string_map_multis_terminate_after_) f_status_t private_f_utf_string_dynamics_resize(const f_array_length_t length, f_utf_string_dynamics_t * const dynamics) { if (dynamics->used + length > F_array_length_t_size_d) { @@ -110,7 +110,7 @@ extern "C" { return F_none; } -#endif // !defined(_di_f_utf_string_dynamics_decrease_by_) || !defined(_di_f_utf_string_dynamics_increase_) || !defined(_di_f_utf_string_dynamics_increase_by_) || !defined(_di_f_utf_string_map_multis_append_) +#endif // !defined(_di_f_utf_string_dynamics_decrease_by_) || !defined(_di_f_utf_string_dynamics_increase_) || !defined(_di_f_utf_string_dynamics_increase_by_) || !defined(_di_f_utf_string_map_multis_append_) || !defined(_di_f_utf_string_map_multis_decrease_by_) || !defined(_di_f_utf_string_map_multis_increase_) || !defined(_di_f_utf_string_map_multis_increase_by_) || !defined(_di_f_utf_string_map_multis_terminate_) || !defined(_di_f_utf_string_map_multis_terminate_after_) #ifdef __cplusplus } // extern "C" diff --git a/level_0/f_utf/c/utf/private-dynamics.h b/level_0/f_utf/c/utf/private-dynamics.h index a660d78..69ece82 100644 --- a/level_0/f_utf/c/utf/private-dynamics.h +++ b/level_0/f_utf/c/utf/private-dynamics.h @@ -33,6 +33,7 @@ extern "C" { * Errors (with error bit) from: f_memory_adjust(). * * @see f_memory_adjust() + * * @see f_utf_string_dynamics_adjust() * @see f_utf_string_dynamics_append() * @see f_utf_string_dynamics_decimate_by() @@ -61,6 +62,7 @@ extern "C" { * Errors (with error bit) from: f_memory_resize(). * * @see f_memory_resize() + * * @see f_utf_string_dynamics_append() * @see f_utf_string_map_multis_append() * @see f_utf_string_map_multis_append_all() @@ -87,6 +89,7 @@ extern "C" { * Errors (with error bit) from: f_memory_resize(). * * @see f_memory_resize() + * * @see f_utf_string_dynamics_append_all() * @see f_utf_string_map_multis_append() * @see f_utf_string_map_multis_append_all() @@ -118,10 +121,15 @@ extern "C" { * @see f_utf_string_dynamics_increase() * @see f_utf_string_dynamics_increase_by() * @see f_utf_string_map_multis_append() + * @see f_utf_string_map_multis_decrease_by() + * @see f_utf_string_map_multis_increase() + * @see f_utf_string_map_multis_increase_by() + * @see f_utf_string_map_multis_terminate() + * @see f_utf_string_map_multis_terminate_after() */ -#if !defined(_di_f_utf_string_dynamics_decrease_by_) || !defined(_di_f_utf_string_dynamics_increase_) || !defined(_di_f_utf_string_dynamics_increase_by_) || !defined(_di_f_utf_string_map_multis_append_) +#if !defined(_di_f_utf_string_dynamics_decrease_by_) || !defined(_di_f_utf_string_dynamics_increase_) || !defined(_di_f_utf_string_dynamics_increase_by_) || !defined(_di_f_utf_string_map_multis_append_) || !defined(_di_f_utf_string_map_multis_decrease_by_) || !defined(_di_f_utf_string_map_multis_increase_) || !defined(_di_f_utf_string_map_multis_increase_by_) || !defined(_di_f_utf_string_map_multis_terminate_) || !defined(_di_f_utf_string_map_multis_terminate_after_) extern f_status_t private_f_utf_string_dynamics_resize(const f_array_length_t length, f_utf_string_dynamics_t * const dynamics) F_attribute_visibility_internal_d; -#endif // !defined(_di_f_utf_string_dynamics_decrease_by_) || !defined(_di_f_utf_string_dynamics_increase_) || !defined(_di_f_utf_string_dynamics_increase_by_) || !defined(_di_f_utf_string_map_multis_append_) +#endif // !defined(_di_f_utf_string_dynamics_decrease_by_) || !defined(_di_f_utf_string_dynamics_increase_) || !defined(_di_f_utf_string_dynamics_increase_by_) || !defined(_di_f_utf_string_map_multis_append_) || !defined(_di_f_utf_string_map_multis_decrease_by_) || !defined(_di_f_utf_string_map_multis_increase_) || !defined(_di_f_utf_string_map_multis_increase_by_) || !defined(_di_f_utf_string_map_multis_terminate_) || !defined(_di_f_utf_string_map_multis_terminate_after_) #ifdef __cplusplus } // extern "C"