gpt4 book ai didi

c++ - 有什么工具可以帮助我阅读 c++ 模板编译错误吗?

转载 作者:行者123 更新时间:2023-11-30 04:33:36 40 4
gpt4 key购买 nike

<分区>

Possible Duplicate:
Deciphering C++ template error messages

每次我收到这种模板错误信息时:

In file included from /usr/include/boost/mpl/set/aux_/iterator.hpp:19:0,
from /usr/include/boost/mpl/set/aux_/begin_end_impl.hpp:19,
from /usr/include/boost/mpl/set/set0.hpp:29,
from /usr/include/boost/parameter/aux_/set.hpp:13,
from /usr/include/boost/parameter/parameters.hpp:48,
from /usr/include/boost/accumulators/framework/accumulator_set.hpp:19,
from /usr/include/boost/accumulators/accumulators.hpp:12,
from src/SimMany.cpp:4:
/usr/include/boost/mpl/has_key.hpp: In instantiation of ‘boost::mpl::has_key<mpl_::arg<1>, mpl_::ar
g<2> >’:
/usr/include/boost/mpl/if.hpp:67:11: instantiated from ‘boost::mpl::if_<boost::mpl::has_key<mpl_:
:arg<1>, mpl_::arg<2> >, boost::mpl::identity<mpl_::arg<1> >, boost::mpl::insert<mpl_::arg<1>, boos
t::mpl::pair<mpl_::arg<2>, mpl_::arg<2> >, mpl_::na> >’
/usr/include/boost/mpl/eval_if.hpp:37:41: instantiated from ‘boost::mpl::eval_if<boost::mpl::has_
key<mpl_::arg<1>, mpl_::arg<2> >, boost::mpl::identity<mpl_::arg<1> >, boost::mpl::insert<mpl_::arg
<1>, boost::mpl::pair<mpl_::arg<2>, mpl_::arg<2> >, mpl_::na> >’
/usr/include/boost/accumulators/framework/depends_on.hpp:330:9: instantiated from ‘boost::accumul
ators::detail::insert_feature<mpl_::arg<1>, mpl_::arg<2> >’
/usr/include/boost/mpl/aux_/preprocessed/gcc/template_arity.hpp:85:5: instantiated from ‘const in
t boost::mpl::aux::template_arity_impl<boost::accumulators::detail::insert_feature<mpl_::arg<1>, mp
l_::arg<2> >, 1>::value’
/usr/include/boost/mpl/aux_/preprocessed/gcc/template_arity.hpp:93:5: instantiated from ‘const in
t boost::mpl::aux::template_arity<boost::accumulators::detail::insert_feature<mpl_::arg<1>, mpl_::a
rg<2> > >::value’
/usr/include/boost/mpl/aux_/preprocessed/gcc/template_arity.hpp:98:30: [ skipping 2 instantiation
contexts ]
/usr/include/boost/mpl/aux_/preprocessed/gcc/apply.hpp:73:1: instantiated from ‘boost::mpl::apply
2<boost::mpl::if_<boost::mpl::is_sequence<mpl_::arg<2> >, boost::accumulators::detail::insert_seque
nce<mpl_::arg<1>, mpl_::arg<2>, void>, boost::accumulators::detail::insert_feature<mpl_::arg<1>, mp
l_::arg<2> > >, boost::mpl::map0<>, boost::accumulators::tag::mean>’
/usr/include/boost/mpl/aux_/preprocessed/gcc/fold_impl.hpp:166:1: instantiated from ‘boost::mpl::
aux::fold_impl<-0x00000000000000001, boost::mpl::aux::transform_iter<boost::mpl::v_iter<boost::accu
mulators::stats<boost::accumulators::tag::mean, boost::accumulators::tag::variance(boost::accumulat
ors::lazy)>, 0l>, boost::mpl::v_iter<boost::accumulators::stats<boost::accumulators::tag::mean, boo
st::accumulators::tag::variance(boost::accumulators::lazy)>, 2l>, boost::mpl::protect<boost::mpl::b
ind1<boost::mpl::quote1<boost::accumulators::as_feature, mpl_::void_>, mpl_::arg<1> >, 0> >, boost:
:mpl::aux::transform_iter<boost::mpl::v_iter<boost::accumulators::stats<boost::accumulators::tag::m
ean, boost::accumulators::tag::variance(boost::accumulators::lazy)>, 2l>, boost::mpl::v_iter<boost:
:accumulators::stats<boost::accumulators::tag::mean, boost::accumulators::tag::variance(boost::accu
mulators::lazy)>, 2l>, boost::mpl::protect<boost::mpl::bind1<boost::mpl::quote1<boost::accumulators
::as_feature, mpl_::void_>, mpl_::arg<1> >, 0> >, boost::mpl::map0<>, boost::mpl::if_<boost::mpl::i
s_sequence<mpl_::arg<2> >, boost::accumulators::detail::insert_sequence<mpl_::arg<1>, mpl_::arg<2>,
void>, boost::accumulators::detail::insert_feature<mpl_::arg<1>, mpl_::arg<2> > > >’
/usr/include/boost/mpl/fold.hpp:39:18: instantiated from ‘boost::mpl::fold<boost::accumulators::d
etail::as_feature_list<boost::accumulators::stats<boost::accumulators::tag::mean, boost::accumulato
rs::tag::variance(boost::accumulators::lazy)>, void>, boost::mpl::map0<>, boost::mpl::if_<boost::mp
l::is_sequence<mpl_::arg<2> >, boost::accumulators::detail::insert_sequence<mpl_::arg<1>, mpl_::arg
<2>, void>, boost::accumulators::detail::insert_feature<mpl_::arg<1>, mpl_::arg<2> > > >’
/usr/include/boost/accumulators/framework/depends_on.hpp:370:13: instantiated from ‘boost::accumu
lators::detail::make_accumulator_tuple<boost::accumulators::stats<boost::accumulators::tag::mean, b
oost::accumulators::tag::variance(boost::accumulators::lazy)>, double, void>’
/usr/include/boost/accumulators/framework/accumulator_set.hpp:122:5: instantiated from ‘boost::ac
cumulators::accumulator_set<double, boost::accumulators::stats<boost::accumulators::tag::mean, boos
t::accumulators::tag::variance(boost::accumulators::lazy)> >’
src/SimMany.cpp:70:7: instantiated from here
/usr/include/boost/mpl/has_key.hpp:33:1: error: no class template named ‘apply’ in ‘struct boost::m
pl::has_key_impl<boost::mpl::non_sequence_tag>’

我真的迷路了。我什至无法直观地解析一个错误消息从哪里开始,另一个错误消息从哪里结束。是否有任何开发工具可以帮助我解决这个问题?

当我使用 boost 库时,这变得特别可怕。 :(

40 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com