Vim OmniCppComplete on vectors of pointers

685 Views Asked by At

I might have done something wrong in the set up but is OmniCppComplete supposed to provide the members/functions of classes when doing this?

vectorofpointers[0]->

At the moment all I get when trying that are things relating to the vector class itself, which obviously isn't very useful. I think it might have been working before I tagged /usr/include/ but I could be wrong.

Also, is it possible to disable the preview window? I find it just clutters up my workspace. And since I enabled ShowPrototypeInAbbr I don't really need it.

Thanks,
Alex

2

There are 2 best solutions below

1
On BEST ANSWER

I do not think it is possible to get proper code completion on the objects that are included in the vector, but someone please correct me if I am mistaken.

To disable the preview window, make sure to not set preview for the the completeopt option, type :help completeopt in Vim for more information.

0
On

We finally have sane code completion for C++ in Vim using GCCSense. With GCCSense it is possible to autocomplete on the contents of a vector.