Suppose I have either:
- A
boost::any
or - An
std::any
(and I'm using C++17)
the type of which I don't know. Is it possible for me to print, or get as a string, the name of the type that's being held by the any
?
Note: Even a mangled type name - the kind you get with typeid(TR).name()
- would be sufficient I can take it from there using abi::__cxa_demangle
.
Aucun commentaire:
Enregistrer un commentaire