[libcxx-commits] [PATCH] D78427: [libcxx] Add c++20 <numbers>

Zoe Carver via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Apr 27 09:06:40 PDT 2020


zoecarver added a comment.

Of course, thanks for working on this. LGTM.

(you'll still need a libc++ maintainer's review)



================
Comment at: libcxx/include/numbers:84
+constexpr T _AlwaysFalse() {
+   static_assert(value<T>, "Require Floating Point types");
+   return T();
----------------
kamleshbhalui wrote:
> zoecarver wrote:
> > Why not `static_assert(false)`? Wouldn't that be more clear? 
> in that case static_assert will fail even when this template is not instantiated.
You're right! I always forget :)


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

https://reviews.llvm.org/D78427





More information about the libcxx-commits mailing list