[*] why the hell

This commit is contained in:
Reece Wilson 2023-04-17 04:30:17 +01:00
parent d29db2200c
commit 9a28cd6862

View File

@ -11,7 +11,7 @@ namespace __audetail
template <class T> template <class T>
struct AuHasSwap struct AuHasSwap
{ {
template <class C> static constexpr AuTrueType Test(decltype(static_cast<void(C:: *)(C &) const>(&C::Swap))); template <class C> static constexpr AuTrueType Test(decltype(static_cast<void(C:: *)(C &)>(&C::Swap)));
template <class C> static constexpr AuFalseType Test(...); template <class C> static constexpr AuFalseType Test(...);
using type = decltype(Test<T>(0)); using type = decltype(Test<T>(0));
}; };
@ -19,7 +19,7 @@ namespace __audetail
template <class T> template <class T>
struct AuHasswap struct AuHasswap
{ {
template <class C> static constexpr AuTrueType Test(decltype(static_cast<void(C:: *)(C &) const>(&C::swap))); template <class C> static constexpr AuTrueType Test(decltype(static_cast<void(C:: *)(C &)>(&C::swap)));
template <class C> static constexpr AuFalseType Test(...); template <class C> static constexpr AuFalseType Test(...);
using type = decltype(Test<T>(0)); using type = decltype(Test<T>(0));
}; };