Author Topic: Code completion - containers  (Read 2558 times)

Offline buzz_lightzyear

  • Single posting newcomer
  • *
  • Posts: 8
Code completion - containers
« on: February 19, 2018, 10:35:04 pm »
Hello!

I have a little problem: when I am creating a variable - lets say myVariable the code completion works very fine. When I am typing "myV" - the IDE shows "myVariable" immediately.

But when I am creating a container like:

Code
std::array<int, 3> myArray{1,2,3};

and I am typing "myA" nothing happens... and so when I am typing "myArray." no available functions were shown. :-(

Can someone help me to solve this problem?

Thx! :-)

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Code completion - containers
« Reply #1 on: February 19, 2018, 11:52:43 pm »
Either the template or the curly brackets are confusing the parser...
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: Code completion - containers
« Reply #2 on: February 20, 2018, 12:27:04 am »
The current code completion plugin is not great with template code....

If you like experimenting you can try the Clang code completion:
https://github.com/yvesdm3000/ClangLib/tree/staging

But you have to compile codeblocks by yourself to be able to install this plugin.

If you want to try it i can write a instruction how to do it....

Offline buzz_lightzyear

  • Single posting newcomer
  • *
  • Posts: 8
Re: Code completion - containers
« Reply #3 on: February 20, 2018, 12:29:06 pm »
Hey!

This would be great! :-) I have already installed Clang also for real-time code checking but its not working so far.

Thx! :-)