Fix unused parameter 't' warnings in eif_*.cpp

This commit is contained in:
Peter Dimov 2021-11-01 01:27:01 +02:00
parent 9d1b59ec6c
commit 309a6bb797
4 changed files with 10 additions and 14 deletions

View File

@ -24,11 +24,11 @@ template <int N> struct dummy {
template<class T>
typename enable_if<is_arithmetic<T>, bool>::type
arithmetic_object(T t, dummy<0> = 0) { return true; }
arithmetic_object(T /*t*/, dummy<0> = 0) { return true; }
template<class T>
typename disable_if<is_arithmetic<T>, bool>::type
arithmetic_object(T t, dummy<1> = 0) { return false; }
arithmetic_object(T /*t*/, dummy<1> = 0) { return false; }
int main()
@ -42,4 +42,3 @@ int main()
return boost::report_errors();
}

View File

@ -60,21 +60,21 @@ namespace A {
template<class T>
typename lazy_enable_if<is_int_or_double<T>, some_traits<T> >::type
foo(T t) { return true; }
foo(T /*t*/) { return true; }
template<class T>
typename lazy_enable_if_c<is_int_or_double<T>::value, some_traits<T> >::type
foo2(T t) { return true; }
foo2(T /*t*/) { return true; }
}
namespace B {
template<class T>
typename lazy_disable_if<is_int_or_double<T>, make_bool<T> >::type
foo(T t) { return false; }
foo(T /*t*/) { return false; }
template<class T>
typename lazy_disable_if_c<is_int_or_double<T>::value, make_bool<T> >::type
foo2(T t) { return false; }
foo2(T /*t*/) { return false; }
}
int main()
@ -95,4 +95,3 @@ int main()
return boost::report_errors();
}

View File

@ -26,13 +26,13 @@ template<class T> struct not_
namespace A {
template<class T>
typename enable_if<is_arithmetic<T>, bool>::type
arithmetic_object(T t) { return true; }
arithmetic_object(T /*t*/) { return true; }
}
namespace B {
template<class T>
typename enable_if<not_<is_arithmetic<T> >, bool>::type
arithmetic_object(T t) { return false; }
arithmetic_object(T /*t*/) { return false; }
}
int main()
@ -47,4 +47,3 @@ int main()
return boost::report_errors();
}

View File

@ -25,11 +25,11 @@ template<class T> struct not_
template<class T>
typename enable_if<is_arithmetic<T>, bool>::type
arithmetic_object(T t) { return true; }
arithmetic_object(T /*t*/) { return true; }
template<class T>
typename enable_if<not_<is_arithmetic<T> >, bool>::type
arithmetic_object(T t) { return false; }
arithmetic_object(T /*t*/) { return false; }
int main()
@ -43,4 +43,3 @@ int main()
return boost::report_errors();
}