[libcxx-commits] [PATCH] D111671: [libcxx] [test] Generalize the conditions for testing bitcasts between long double, double and int128

Mark de Wever via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Oct 13 10:16:27 PDT 2021


Mordante accepted this revision as: Mordante.
Mordante added a comment.

It seems we already relay on `__SIZEOF_*` in our code, including in `<bitset>` so I don't see that as a big issue.
LGTM modulo one minor remark.



================
Comment at: libcxx/test/std/numerics/bit/bit.cast/bit_cast.pass.cpp:233
+#endif
+#if !defined(_LIBCPP_HAS_NO_INT128)
+#if defined(__SIZEOF_LONG_DOUBLE__) && defined(__SIZEOF_INT128__) && __SIZEOF_LONG_DOUBLE__ == __SIZEOF_INT128__
----------------
In `__config` there's this definition
```
#ifndef __SIZEOF_INT128__
#define _LIBCPP_HAS_NO_INT128
#endif
```
So this test can be removed.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D111671/new/

https://reviews.llvm.org/D111671



More information about the libcxx-commits mailing list