1 //===----------------------------------------------------------------------===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
8 #ifndef TEST_STD_SHARED_PTR_RESET_H
9 #define TEST_STD_SHARED_PTR_RESET_H
12 #include <type_traits>
14 template <class T
, class... Args
>
15 std::false_type
test_has_reset(...);
17 template <class T
, class... Args
>
18 typename
std::enable_if
<std::is_same
<decltype(std::declval
<T
>().reset(std::declval
<Args
>()...)), void>::value
,
22 template <class T
, class... Args
>
23 using HasReset
= decltype(test_has_reset
<T
, Args
...>(0));
25 #endif // TEST_STD_SHARED_PTR_RESET_H