编译C++代码出现下面错误no type named ‘iterator_category’ in ‘class std::vector<double>’ 20

Infileincludedfrom/usr/include/c++/4.6/bits/stl_algobase.h:66:0,from/usr/include/c++/... In file included from /usr/include/c++/4.6/bits/stl_algobase.h:66:0,
from /usr/include/c++/4.6/bits/char_traits.h:41,
from /usr/include/c++/4.6/ios:41,
from /usr/include/c++/4.6/ostream:40,
from /usr/include/c++/4.6/iostream:40,
from lineartrend_notest.cpp:7:
/usr/include/c++/4.6/bits/stl_iterator_base_types.h: 在全局域:
/usr/include/c++/4.6/bits/stl_iterator_base_types.h:在‘std::iterator_traits<std::vector<double> >’的实例化中:
/usr/include/c++/4.6/bits/stl_vector.h:1090:24:自‘void std::vector<_Tp, _Alloc>::_M_initialize_dispatch(_InputIterator, _InputIterator, std::__false_type) [with _InputIterator = std::vector<double>, _Tp = std::vector<double>, _Alloc = std::allocator<std::vector<double> >]’实例化
/usr/include/c++/4.6/bits/stl_vector.h:340:4:自‘std::vector<_Tp, _Alloc>::vector(_InputIterator, _InputIterator, const allocator_type&) [with _InputIterator = std::vector<double>, _Tp = std::vector<double>, _Alloc = std::allocator<std::vector<double> >, std::vector<_Tp, _Alloc>::allocator_type = std::allocator<std::vector<double> >]’实例化
xg_math_stat.h:320:116:自‘regress2<T>::regress2(const std::vector<T>&, const std::vector<T>&) [with T = double]’实例化
lineartrend_notest.cpp:26:28:从此处实例化
/usr/include/c++/4.6/bits/stl_iterator_base_types.h:166:53: 错误: no type named ‘iterator_category’ in ‘class std::vector<double>’
我知道应该是命名空间出了问题,但不知道到底哪里有问题
展开
 我来答
百度网友b5ec8c602
2014-01-22 · TA获得超过1086个赞
知道小有建树答主
回答量:360
采纳率:0%
帮助的人:280万
展开全部
把代码贴出来把?你可以双击一下错误···会跳到错误的地方
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式