Skip to content
Snippets Groups Projects
Commit 526f8970 authored by Felix Gruber's avatar Felix Gruber Committed by Christoph Grüninger
Browse files

[cleanup] replace remove_pointer with std:: implementation

parent b77df070
Branches
Tags
No related merge requests found
......@@ -26,12 +26,5 @@ int main() {
assert( Dune::is_lvalue_reference<int&>::value );
assert( not Dune::is_lvalue_reference<int&&>::value );
// Test remove_pointer
assert( (Dune::is_same<int, Dune::remove_pointer<int>::type>::value) );
assert( (Dune::is_same<int, Dune::remove_pointer<int*>::type>::value) );
assert( (Dune::is_same<int*, Dune::remove_pointer<int**>::type>::value) );
assert( (Dune::is_same<const int, Dune::remove_pointer<const int*>::type>::value) );
assert( (Dune::is_same<int, Dune::remove_pointer<int* const>::type>::value) );
return 0;
}
......@@ -209,20 +209,7 @@ namespace Dune
: public integral_constant<bool, (__is_lvalue_reference_helper<T>::value)>
{ };
template<typename _Tp>
struct __remove_pointer_helper
{ typedef _Tp type; };
template<typename _Tp>
struct __remove_pointer_helper<_Tp*>
{ typedef _Tp type; };
/** \brief Return the type a pointer type points to
*/
template<typename _Tp>
struct remove_pointer
: public __remove_pointer_helper<typename remove_const<_Tp>::type >
{ };
using std::remove_pointer;
/**
\brief template which always yields a false value
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment