rcpputils  master
C++ API providing common utilities and data structures.
Public Types | List of all members
rcpputils::remove_pointer< T > Struct Template Reference

Type traits for deducing the data type of T from a pointer or smart pointer. More...

#include <pointer_traits.hpp>

Public Types

using type = typename details::remove_pointer< typename std::remove_reference< T >::type, details::is_smart_pointer< T >::value >::type
 

Detailed Description

template<class T>
struct rcpputils::remove_pointer< T >

Type traits for deducing the data type of T from a pointer or smart pointer.

In comparison to the existing type trait for pointer in the stdlib std::remove_pointer<T> https://en.cppreference.com/w/cpp/types/remove_pointer this trait is enhancing it for checking of smart pointer types as well. The valid pointer types are T*, std::shared_pointer<T> and std::unique_ptr<T>

Member Typedef Documentation

◆ type

template<class T >
using rcpputils::remove_pointer< T >::type = typename details::remove_pointer< typename std::remove_reference<T>::type, details::is_smart_pointer<T>::value>::type

The documentation for this struct was generated from the following file: