[libc-commits] [PATCH] D149594: [libc] Add explicit constructor calls to fix compilation when using UInt<T>

Mikhail Ramalho via Phabricator via libc-commits libc-commits at lists.llvm.org
Mon May 1 09:22:16 PDT 2023


mikhail.ramalho created this revision.
mikhail.ramalho added reviewers: sivachandra, michaelrj.
Herald added subscribers: libc-commits, asb, ecnelises, tschuett, s.egerton, PkmX, simoncook, arichardson.
Herald added projects: libc-project, All.
mikhail.ramalho requested review of this revision.
Herald added a subscriber: pcwang-thead.

This patch is similar to 86fe88c8d9 <https://reviews.llvm.org/rG86fe88c8d91bb30870007c48ca71672fda8d6492> 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


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D149594

Files:
  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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D149594.518470.patch
Type: text/x-patch
Size: 9195 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20230501/a64b39f9/attachment.bin>


More information about the libc-commits mailing list