[Bug libstdc++/15910] can't compile self defined void distance(std::vector<T>, std::vector<T>)
pinskia at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Wed Aug 10 03:17:00 GMT 2005
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-08-10 03:17 -------
(In reply to comment #72)
> encountered the problem before. Not to say understand the problem. As the
> very beginning, adding a message like `In instantiation of std::distance...'
> will be helpful.
But it is not instantiating std::distance just yet, it is looking at the return values/parameter types.
ICC produces about the same error message:
/opt/intel/include/c++/xutility(290): error: class "std::vector<double, std::allocator<double>>" has no
member "iterator_category"
typedef typename _Iter::iterator_category iterator_category;
^
detected during instantiation of class "std::iterator_traits<_Iter> [with _Iter=std::vector<double,
std::allocator<double>>]" at line 12 of "t.cc"
compilation aborted for t.cc (code 2)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15910
More information about the Gcc-bugs
mailing list