You can retrieve the implementation defined name of a type in runtime by using the .name()
member function of the std::type_info
object returned by typeid
.
#include <iostream>
#include <typeinfo>
int main()
{
int speed = 110;
std::cout << typeid(speed).name() << '\n';
}
Output (implementation-defined):
int