1const std::type_info& ti1 = typeid(A);
2const std::type_info& ti2 = typeid(A);
3
4assert(&ti1 == &ti2); // not guaranteed
5assert(ti1.hash_code() == ti2.hash_code()); // guaranteed
6assert(std::type_index(ti1) == std::type_index(ti2)); // guaranteed