Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Indexer problem with typedef for iterator and std::vector::insert
Indexer problem with typedef for iterator and std::vector::insert [message #868725] Wed, 02 May 2012 13:00
Nathan Hüsken is currently offline Nathan HüskenFriend
Messages: 27
Registered: November 2010
Junior Member
Hi,

I am not sure if I should make a bug report out of this.
I have searched bugzilla, but could not find a similar bug.

With eclipse Juno Release, I created a C++ executable project (Hello World).
I replaced the contents of main with:


#include <vector>
#include <boost/smart_ptr.hpp>

int main() {
typedef boost::shared_ptr<int> INTPTR;
std::vector<INTPTR> m_ints;
typedef std::vector<INTPTR>::iterator ITER;
ITER iter = m_ints.begin();
m_ints.insert(iter, 0);
}

And now I get from the indexer for the "insert" in the last code line:

Invalid arguments ' Candidates are: __gnu_cxx::__normal_iterator<boost::shared_ptr<int> *,std::vector<boost::shared_ptr<int>,std::allocator<boost::shared_ptr<int>>>> insert(__gnu_cxx::__normal_iterator<boost::shared_ptr<int>
*,std::vector<boost::shared_ptr<int>,std::allocator<boost::shared_ptr<int>>>>, const boost::shared_ptr<int> &) void insert(__gnu_cxx::__normal_iterator<boost::shared_ptr<int> *,std::vector<boost::shared_ptr<int>,std::allocator<boost::shared_ptr<int>>>>, unsigned long
int, const boost::shared_ptr<int> &) void insert(__gnu_cxx::__normal_iterator<boost::shared_ptr<int> *,std::vector<boost::shared_ptr<int>,std::allocator<boost::shared_ptr<int>>>>, #10000, #10000) '

I appended the indexer log.

If i removed the typedefs (and type the types directly), the problem is solved.
Is there a solution?

Thanks!
Nathan
  • Attachment: parser.log
    (Size: 62.19KB, Downloaded 271 times)
Previous Topic:indexer can not deal with std::vector<boost::smart_ptr<...> >
Next Topic:Errors when attempting to build C++ project
Goto Forum:
  


Current Time: Fri Apr 19 16:40:22 GMT 2024

Powered by FUDForum. Page generated in 0.01871 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top