关于Boost容器中.template、get<1>和project<0>的技术疑问
C++容器代码疑问
auto& lookup = container.template get<1>(); container.relocate(container.begin(),container.template project<0>(it));
1. 关于.template的理解
根据我查到的资料,容器上使用的template关键字是用来调用模板成员的,这个理解对吗?
2. 关于project<0>(it)和get<1>的含义
我找到了project方法的定义,知道它需要迭代器作为参数,但搞不懂project<0>以及get<1>到底是什么意思。查了Boost Variant相关文档和Stack Overflow的帖子,还是没弄明白。
内容的提问来源于stack exchange,提问作者Keorus
相关产品推荐
相关产品推荐

