运行期以索引获取tuple元素-C++17
摘要://运行期以索引获取tuple元素-C++17 //需支持C++17及以上标准的编译器,VS2017 15.5.x、CodeBlocks 16.01 gcc 7.2 //参见:http://purecpp.org/?p=1581 #include #include using namespace std; template void visit(T& tup, size_t i) { ...
阅读全文
posted @ 2017-12-24 00:36