Functor returning the dereferenced value of the argument. More...
#include <Dereference.h>
Public Types | |
using | argument_type = T |
using | reference_type = typename std::add_lvalue_reference< typename dereferenced_type< T, CanDereference >::type >::type |
Public Member Functions | |
reference_type | operator() (argument_type &ref) const |
Functor returning the dereferenced value of the argument.
T | type of the argument |
CanDereference | whether T can be dereferenced or not |
The functor defines a call operator returning:
The behaviour is therefore determined by the CanDereference parameter. Note that the second parameter must express correctly whether the first type can be dereferenced or not. Clearly, this class is not very useful by itself, since we have to tell it how to do the trick. It is used in association with has_dereference_class.
This class is state-less.
Definition at line 132 of file Dereference.h.
using lar::util::details::dereference_class< T, CanDereference >::argument_type = T |
Definition at line 133 of file Dereference.h.
using lar::util::details::dereference_class< T, CanDereference >::reference_type = typename std::add_lvalue_reference <typename dereferenced_type<T, CanDereference>::type>::type |
Definition at line 135 of file Dereference.h.
|
inline |
Definition at line 137 of file Dereference.h.