我以前曾使用过一些Boost.MPL库,我正在尝试更多地了解Boost.Hana。我似乎对图书馆完全误解了。我希望用任意数量的模板参数实例化一个对象,根据这些类型作为成员创建对象元组,并在以后迭代或以其他方式使用该元组。has no member named 'apply'
所以元组不包含Bar<T>类型的对象,而是boost::hana "
我使用以下模板声明一组类型:using DependencySet = boost::hana::set<boost::hana::type<T>...>;我希望能够从集合中提取出这些类型并放入另一个容器中。DependencySet<Dependencies...>> using type = SomeOtherType<Dependencies...&
我想知道为什么在这段代码中,i的类型是一个空的可选选项。auto t = boost::hana::make_tuple(boost::hana::type_c<int>, boost::hana::type_c<double>);
auto i = boost::hana::index_if(t, boost::hana::is_a<