PR libstdc++/82254 fix std::is_nothrow_invocable_r w.r.t throwing conversions
authorJonathan Wakely <jwakely@redhat.com>
Tue, 19 Sep 2017 14:33:51 +0000 (15:33 +0100)
committerJonathan Wakely <redi@gcc.gnu.org>
Tue, 19 Sep 2017 14:33:51 +0000 (15:33 +0100)
commitc4b06e7f1de6dff6a4c087bcf554451e9887d0f3
tree8663e2cd36d2eb27eef959675595ee25e8f9d74b
parente32d238855968bce82a6cca4655298c42185508d
PR libstdc++/82254 fix std::is_nothrow_invocable_r w.r.t throwing conversions

PR libstdc++/82254
* include/std/type_traits (__is_invocable): Add partial specialization
for INVOKE<void> case and remove is_void<R> check from partial
specialization for INVOKE<R> case.
(__is_nt_invocable_impl): New helper for is_nothrow_invocable_r.
(is_nothrow_invocable_r): Use __is_nt_invocable_impl.
* testsuite/20_util/is_nothrow_invocable/value.cc: Add tests for
conversions that can throw or fail to convert. Use static assert
strings to explain negative results.
* testsuite/20_util/is_nothrow_invocable/value_ext.cc: Use
is_nothrow_constructible in is_nt_invocable_conv.

From-SVN: r252977
libstdc++-v3/ChangeLog
libstdc++-v3/include/std/type_traits
libstdc++-v3/testsuite/20_util/is_nothrow_invocable/value.cc
libstdc++-v3/testsuite/20_util/is_nothrow_invocable/value_ext.cc