From: Kevin Day Date: Sat, 14 Jan 2023 06:49:09 +0000 (-0600) Subject: Bugfix: The f_int_128_t is using incorrect size. X-Git-Tag: 0.6.3~3 X-Git-Url: https://git.kevux.org/?a=commitdiff_plain;h=de6cf7f23de860c9202eb8b7758f2f999a4fd7db;p=fll Bugfix: The f_int_128_t is using incorrect size. The wrong wrapping define macros are being used. - Use __SIZEOF_INT128__ instead of _di_f_int_128_t_. - Use #ifdef instead of #ifndef. --- diff --git a/level_0/f_type/c/type.h b/level_0/f_type/c/type.h index df67b39..aae9f66 100644 --- a/level_0/f_type/c/type.h +++ b/level_0/f_type/c/type.h @@ -186,7 +186,7 @@ extern "C" { #define F_type_size_64_positive_d 0x7ffffffffffffffe #define F_type_size_64_unsigned_d 0xfffffffffffffffe - #ifndef _di_f_int_128_t_ + #ifdef __SIZEOF_INT128__ #define F_type_size_128_negative_d 0x7fffffffffffffffffffffff #define F_type_size_128_positive_d 0x7ffffffffffffffffffffffe #define F_type_size_128_unsigned_d 0xfffffffffffffffffffffffe @@ -194,7 +194,7 @@ extern "C" { #define F_type_size_128_negative_d F_type_size_64_negative_d #define F_type_size_128_positive_d F_type_size_64_positive_d #define F_type_size_128_unsigned_d F_type_size_64_unsigned_d - #endif // _di_f_int_128_t_ + #endif // __SIZEOF_INT128__ #define F_type_size_max_8_negative_d 0x80 #define F_type_size_max_8_positive_d 0x7f @@ -212,7 +212,7 @@ extern "C" { #define F_type_size_max_64_positive_d 0x7fffffffffffffff #define F_type_size_max_64_unsigned_d 0xffffffffffffffff - #ifndef _di_f_int_128_t_ + #ifdef __SIZEOF_INT128__ #define F_type_size_max_128_negative_d 0x800000000000000000000000 #define F_type_size_max_128_positive_d 0x7fffffffffffffffffffffff #define F_type_size_max_128_unsigned_d 0xffffffffffffffffffffffff @@ -220,7 +220,7 @@ extern "C" { #define F_type_size_max_128_negative_d F_type_size_max_64_negative_d #define F_type_size_max_128_positive_d F_type_size_max_64_positive_d #define F_type_size_max_128_unsigned_d F_type_size_max_64_unsigned_d - #endif // _di_f_int_128_t_ + #endif // __SIZEOF_INT128__ #endif // _di_f_type_sizes_d_ /** @@ -946,7 +946,7 @@ extern "C" { * * This provides the types without the normal "f_" leading prefixes to be more in line with the core types like int64_t. */ -#ifndef __SIZEOF_INT128__ +#ifdef __SIZEOF_INT128__ #ifndef _di_f_int128_t_ typedef __int128_t int128_t;