[libc] Add explicit constructor calls to fix compilation when using UInt<T>
authorMikhail R. Gadelha <mikhail@igalia.com>
Tue, 16 May 2023 15:53:07 +0000 (12:53 -0300)
committerMikhail R. Gadelha <mikhail@igalia.com>
Tue, 16 May 2023 15:59:32 +0000 (12:59 -0300)
commitb663993067ffb5800632ad41ea7f2f92caab1093
tree27e589d8714bd5a8553448694993b2c53ec6dcef
parent845f3e57b2c644a60e1d4b98b7490742b554f2a7
[libc] Add explicit constructor calls to fix compilation when using UInt<T>

This patch is similar to 86fe88c8d9 and adds several explicit
constructor calls (bool(...), uint64_t(...), uint8_t(...)) that are
needed when we use UInt<T> (in my case UInt<128> in riscv32).

This patch also adds two operators to UInt<T>:
* operator/= required by printf_core/float_hex_converter.h:148
* operator-- required by FPUtil/ManipulationFunctions.h:166

Reviewed By: sivachandra, lntue

Differential Revision: https://reviews.llvm.org/D149594
libc/src/__support/FPUtil/generic/sqrt.h
libc/src/__support/UInt.h
libc/src/__support/float_to_string.h
libc/src/__support/str_to_float.h
libc/src/stdio/printf_core/char_converter.h
libc/src/stdio/printf_core/float_dec_converter.h
libc/src/stdio/printf_core/float_hex_converter.h
libc/src/stdio/printf_core/float_inf_nan_converter.h
libc/src/stdio/printf_core/int_converter.h