[libcxx-commits] [PATCH] D58019: Add is_nothrow_convertible (P0758R1)
Zoe Carver via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Feb 12 10:31:22 PST 2019
zoecarver marked an inline comment as done.
zoecarver added inline comments.
================
Comment at: include/type_traits:1558
+ __or_<
+ is_void<_Fm>, is_function<_To>, is_array<_To>
+ >::value
----------------
zoecarver wrote:
> ldionne wrote:
> > I don't think this is useful anymore, as this should be handled by `std::is_convertible`. IOW, I think only the test for `noexcept`-ness of the conversion needs to exist, not for convertibility.
> Good catch, you're completely right. In fact, we could probably simplify this a lot and just have it use `is_nothrow_constructible<_Fm, _To>`. I am a bit hesitant to do that because it isn't what `is_nothrow_constructible`'s intended use is, what do you think?
Actually correction: `void` will not work in the below `__test_noexcept` method so it has to have its own overload. But I can get rid of the `is_array`/`is_function` checks (because those will be caught by `std::is_convertible`).
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D58019/new/
https://reviews.llvm.org/D58019
More information about the libcxx-commits
mailing list