腾讯云
开发者社区
文档
建议反馈
控制台
登录/注册
首页
学习
活动
专区
工具
TVP
最新优惠活动
文章/答案/技术大牛
搜索
搜索
关闭
发布
精选内容/技术社群/优惠产品,
尽在小程序
立即前往
文章
问答
(2836)
视频
沙龙
2
回答
boost
hana
:从一个集合和一个默认值创建一个映射
、
、
、
、
我有一个boost::
hana
::类型集,并想用它创建一个映射,其中的值是布尔值。// I have a
hana
set:auto wan
浏览 0
提问于2017-03-02
得票数 2
回答已采纳
1
回答
*mpl::类型和字符字符串的映射
、
、
如下所示 pair<int,"int"> , pair<bool,"bool">可能吗?如果没有,还有什么可供选择的?
浏览 2
提问于2015-09-27
得票数 1
回答已采纳
1
回答
参考助推式fold_left兰巴呼叫
、
我想遍历一个多时间点(地图的地图),例如:map<int,map<char, string>>在boost
hana
的帮助下。auto at = [](auto &map, auto key) -> auto& { }; }以前没有
hana
浏览 2
提问于2015-09-21
得票数 3
回答已采纳
1
回答
boost
hana
index_if和类型
、
、
auto t = boost::
hana
::make_tuple(boost::
hana
::type_c<int>, boost::
hana
::type_c<double>);对我来说,应该是optional<
hana
::size_t<1>&g
浏览 2
提问于2018-09-18
得票数 2
回答已采纳
1
回答
在C++14中使用
hana
::transform转换元组内部的类型
、
、
、
、
我正在尝试使用Boost的
hana
::transform来更改
hana
::tuple中的类型。尝试2谢谢你的帮助。编辑#include <boost/
hana
.hpp> #include <boost/
hana
/t
浏览 0
提问于2018-04-11
得票数 6
回答已采纳
2
回答
更改编译时的运行时研究
、
、
所以简单的方法是做这样的事情:
hana
::make_pair(
hana
::to_tuple(
hana
::tuple_t<C1, C2>), type_c<Storage>),struct
浏览 4
提问于2017-03-29
得票数 1
回答已采纳
1
回答
Boost.
Hana
:在constexpr上下文中将值的元组转换为相应类型的元组
、
、
、
、
namespace
hana
= boost::
hana
; auto value_tuple =
hana
::make_tuple(1, 'a'); constexpr auto type_tuple =
hana
::make_tuple(
hana
::type_c<int>
浏览 18
提问于2020-05-13
得票数 1
2
回答
如何逆转
hana
::string
、
、
有人知道如何逆转助推::
hana
::string吗?以下内容不起作用:#include <boost/
hana
/reverse.hpp>auto s2 = boost::
hana
::reverse(s);boost/
hana
/reverse.hpp:36
浏览 0
提问于2018-12-14
得票数 1
回答已采纳
1
回答
用boost.
hana
自省结构定义
、
、
从MPL迁移到
Hana
!所以假设我们有正常的 BOOST_
HANA
_DEFINE_STRUCT(Person, (int, age));文档给出了一个内省此结构的对象的示例,大致如下static_assert(
hana
::keys(john) ==
hana
::make_tuple("name
浏览 0
提问于2018-06-29
得票数 2
回答已采纳
1
回答
如何构造给定T和元素数n的
hana
::tuple_t<T,...>
、
、
、
、
我能想到的最短的事情就是 return
hana
::if_( count ==
hana
::int_c<0>,
hana
::nothing,
hana
::just(
hana
::make_pair
浏览 4
提问于2016-10-17
得票数 5
回答已采纳
1
回答
如何将boost::
hana
::map转换为lambdas
、
、
我有以下代码void my_func(T& /*var*/)};
hana
::make_pair(
hana
::type_c<std::uint32_t>,
hana
::integral_c<std::uint8_t, 1>),
hana
::make_pair(
hana
::type_c<std::
浏览 25
提问于2020-05-20
得票数 0
回答已采纳
2
回答
如何赋值给结构对象的成员?
、
、
我正在使用Boost.
Hana
迈出我的第一步,所以请耐心等待。我有过 #include <boost/
hana
.hpp>using namespace
hana
::literals; A a;
hana
::for_each(
hana
::zip(
hana
::members(a), tuple), [](
浏览 34
提问于2019-01-17
得票数 4
回答已采纳
1
回答
STL与
Hana
元组的转换
、
#include <boost/
hana
.hpp>#include <tuple> { float y{3.14}; auto t =
hana
::to<
hana
::tuple_tag>(std::tie(x, y, z));
浏览 2
提问于2015-12-16
得票数 1
回答已采纳
2
回答
将integral_constants的元组转换为ints的组成元组
、
、
、
、
假设我有一个
hana
::integral_constant的元组,如下所示:
hana
::integral_constant<int,1>());constexpr auto constexpr_tuple = <em
浏览 0
提问于2018-03-09
得票数 1
回答已采纳
3
回答
如何为Boost.
Hana
结构实现相等比较操作符?
、
、
假设我们有Boost.
Hana
结构: BOOST_
HANA
_DEFINE_STRUCT(SomeStruct, (int, x), (double, y),constexpr bool operator == (SomeStruct const& other) { return boost::<em
浏览 17
提问于2019-12-09
得票数 2
回答已采纳
1
回答
将constexpr结构转换为运行时结构
、
、
、
、
我试图使用一个模板类(此处为Foo),其基本类型如下:
hana
::tuple<
hana
::pair<
hana
::type<int>,
hana
::type<Runtime>>>在编译
浏览 1
提问于2017-04-29
得票数 4
回答已采纳
1
回答
模板的
hana
类型
、
、
我试图使用boost::
hana
生成一个使用模板模板的类型,但遇到了麻烦。template<typename T> T y;现在,我想为每个BarX<T>类创建一个Foo<BarImpl>:
hana
::for_each(
浏览 11
提问于2017-12-07
得票数 3
回答已采纳
1
回答
hana
:为什么我不能过滤一套?
、
、
我使用boost::
hana
,我想过滤一个boost::
hana
::set。#include <boost/
hana
.hpp> using namespace boost::
hana
;static assertion failed:
hana
::remove_if(xs, predicate) requires 'xs' to be a Mon
浏览 0
提问于2018-09-30
得票数 0
回答已采纳
3
回答
在boost
hana
中过滤元组
、
Ts, class T> auto types =
hana
::to<
hana
::tuple_tag>(
hana
::tuple_t<Ts...>);} auto ht =
ha
浏览 9
提问于2015-11-25
得票数 3
回答已采纳
2
回答
Boost
hana
获得第一次匹配指数
、
、
、
、
因此,我试图使用boost::
hana
创建一个库,该库需要基于以下值获取元素索引的功能://^^^^^ would be a boost::
hana
::int
浏览 3
提问于2015-11-29
得票数 3
回答已采纳
点击加载更多
扫码
添加站长 进交流群
领取专属
10元无门槛券
手把手带您无忧上云
相关
资讯
HANA 1.0 vs HANA 2.0
HANA性能浅析
SAP HANA 平台的优势
SAP HANA技术总结
从HANA到Greenplum
热门
标签
更多标签
云服务器
ICP备案
对象存储
即时通信 IM
实时音视频
活动推荐
运营活动
广告
关闭
领券