Print type:
#include <cxxabi.h>
...
auto print_type = []<typename TT>(TT&&) {
int s; return abi::__cxa_demangle(typeid(TT).name(),0,0,&s); };
In variant:
std::visit(print_type, variant);
Print type:
#include <cxxabi.h>
...
auto print_type = []<typename TT>(TT&&) {
int s; return abi::__cxa_demangle(typeid(TT).name(),0,0,&s); };
In variant:
std::visit(print_type, variant);