...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
boost::typeindex::type_id
// In header: <boost/type_index.hpp> template<typename T> type_index type_id();
Function to get boost::typeindex::type_index for a type T. Removes const, volatile && and & modifiers from T.
Example:
type_index ti = type_id<int&>(); std::cout << ti.pretty_name(); // Outputs 'int'
Template Parameters: |
|
||
Returns: |
boost::typeindex::type_index with information about the specified type T. |
||
Throws: |
Nothing. |