class type_info;
typeid
operator (as a const-qualified lvalue). Although its actual dynamic type may be of a derived class.typeid
can be applied to any type or any expression that has a type.const
or volatile
qualified type is identified as its unqualified equivalent. typedef
type is considered the same as its aliased type.typeid
is applied to a reference or dereferenced pointer to an object of a polymorphic class type (a class declaring or inheriting a virtual function), it considers its dynamic type (i.e., the type of the most derived object). This requires the RTTI (Run-time type information) to be available.typeid
is applied to a dereferenced null pointer, a bad_typeid exception is thrown.typeid
extends to the end of the program.type_info
are private: objects of this type cannot be copied.type_info
are deleted: objects of this type cannot be copied.