forked from boostorg/container_hash
Compare commits
3 Commits
boost-1.84
...
feature/is
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7288df8bee | ||
|
|
5c2d5e5b36 | ||
|
|
db8743e1c3 |
17
.github/workflows/ci.yml
vendored
17
.github/workflows/ci.yml
vendored
@@ -124,24 +124,33 @@ jobs:
|
||||
- toolset: clang
|
||||
compiler: clang++-13
|
||||
cxxstd: "11,14,17,20,2b"
|
||||
os: ubuntu-22.04
|
||||
container: ubuntu:22.04
|
||||
os: ubuntu-latest
|
||||
install: clang-13
|
||||
- toolset: clang
|
||||
compiler: clang++-14
|
||||
cxxstd: "11,14,17,20,2b"
|
||||
os: ubuntu-22.04
|
||||
container: ubuntu:22.04
|
||||
os: ubuntu-latest
|
||||
install: clang-14
|
||||
- toolset: clang
|
||||
compiler: clang++-15
|
||||
cxxstd: "11,14,17,20,2b"
|
||||
os: ubuntu-22.04
|
||||
container: ubuntu:22.04
|
||||
os: ubuntu-latest
|
||||
install: clang-15
|
||||
- toolset: clang
|
||||
compiler: clang++-16
|
||||
cxxstd: "11,14,17,20,2b"
|
||||
os: ubuntu-latest
|
||||
container: ubuntu:23.04
|
||||
os: ubuntu-latest
|
||||
install: clang-16
|
||||
- toolset: clang
|
||||
compiler: clang++-17
|
||||
cxxstd: "11,14,17,20,2b"
|
||||
container: ubuntu:23.10
|
||||
os: ubuntu-latest
|
||||
install: clang-17
|
||||
- toolset: clang
|
||||
cxxstd: "11,14,17,2a"
|
||||
os: macos-11
|
||||
|
||||
@@ -26,7 +26,7 @@ template<class T> struct is_tuple_like_<T, std::integral_constant<bool, std::tup
|
||||
namespace container_hash
|
||||
{
|
||||
|
||||
template<class T> struct is_tuple_like: hash_detail::is_tuple_like_<T>
|
||||
template<class T> struct is_tuple_like: hash_detail::is_tuple_like_< typename std::remove_cv<T>::type >
|
||||
{
|
||||
};
|
||||
|
||||
|
||||
@@ -70,20 +70,36 @@ int main()
|
||||
using boost::container_hash::is_tuple_like;
|
||||
|
||||
BOOST_TEST_TRAIT_FALSE((is_tuple_like<void>));
|
||||
BOOST_TEST_TRAIT_FALSE((is_tuple_like<void const>));
|
||||
|
||||
BOOST_TEST_TRAIT_FALSE((is_tuple_like<int>));
|
||||
BOOST_TEST_TRAIT_FALSE((is_tuple_like<int const>));
|
||||
|
||||
BOOST_TEST_TRAIT_FALSE((is_tuple_like<X>));
|
||||
BOOST_TEST_TRAIT_FALSE((is_tuple_like<X const>));
|
||||
|
||||
BOOST_TEST_TRAIT_FALSE((is_tuple_like<int[2]>));
|
||||
BOOST_TEST_TRAIT_FALSE((is_tuple_like<int const [2]>));
|
||||
|
||||
#if !defined(BOOST_NO_CXX11_HDR_TUPLE) && !BOOST_WORKAROUND(BOOST_MSVC, <= 1800)
|
||||
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::pair<int, X> >));
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::pair<int, X> const>));
|
||||
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::tuple<> >));
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::tuple<> const>));
|
||||
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::tuple<X> >));
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::tuple<X> const>));
|
||||
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::tuple<X, X> >));
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::tuple<X, X> const>));
|
||||
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::tuple<X, X, X> >));
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like< std::tuple<X, X, X> const>));
|
||||
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like<user::Y>));
|
||||
BOOST_TEST_TRAIT_TRUE((is_tuple_like<user::Y const>));
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user