mclow.lists marked 4 inline comments as done.
mclow.lists added inline comments.


================
Comment at: include/bit:254
+
+    if      constexpr (sizeof(_Tp) <= sizeof(unsigned int))
+       return __clz(static_cast<unsigned int>(__t))
----------------
EricWF wrote:
> Cool use of `if constexpr`.
> 
> Please clang-format these changes.
I really like this formatting; it reflects the structure of the code.


================
Comment at: include/bit:405
+
+template <class _Tp>
+inline _LIBCPP_INLINE_VISIBILITY constexpr
----------------
EricWF wrote:
> Please write the SFINAE using a default template parameter.
> 
> See 
> http://libcxx.llvm.org/docs/DesignDocs/ExtendedCXX03Support.html#use-default-template-parameters-for-sfinae
I think that document is misguided in cases like this; the `enable_if` on the 
return type cannot be "interfered with" by the caller the way an extra template 
parameter can be.




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

https://reviews.llvm.org/D51262



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to