3 ms·
I think all the answers will probably come when C++17 support is good enough. See the example at [1], in particular the "overloaded" bit. I think my current GC
by lomnakkus 9y ago
I think all the answers will probably come when C++17 support is good enough. See the example at [1], in particular the "overloaded" bit.
I think my current GCC 7.2 should support it, but I don't think my current Clang 4.0.1 does. EDIT: Just tested and I can confirm that.
[1] http://en.cppreference.com/w/cpp/utility/variant/visit#Example http://en.cppreference.com/w/cpp/utility/variant/visit#Examp...