I'm using Code::Blocks 13.12, and it seems call tip and autocomplete is not working for variables declared with C++11 auto type?
Example with explicit type:
MyType* thing = new MyType;
thing-> //after typing "->", a list of call tips pops up (usually)
Example with auto type:
auto thing = new MyType;
thing-> //no call tips pops up after typing "->"
Are there any plans to implement call tip and autocomplete for auto types? Or is there some plugin or setting which allow this alrady?
From what I can tell, several IDEs already support this (Visual Studio 201x, Eclipse, Qt Creator 2.7.0, KDevelop 4.5.1). See this question on stackoverflow:
http://stackoverflow.com/questions/19625115/which-ides-and-text-editors-can-deduce-type-of-variables-declared-using-auto-key (http://stackoverflow.com/questions/19625115/which-ides-and-text-editors-can-deduce-type-of-variables-declared-using-auto-key)
I think the auto feature is a very useful addition for several reasons, and I've already replaced a bunch of explicit type names with auto in my project. But it's a pity that the call tips don't show up there anymore.
Code::Blocks is my favorite IDE and I don't want to change to any of the other's I mentioned above. If there is some indication that call tips and autocomplete for auto types is going to be fixed soon-ish, I'll just hold out without call tips until then :)
No?
I don't think there are plans to implement auto in our parser anytime soon. Probably you can try Alpha's clang based code completion plugin...
Quote from: oBFusCATed on July 28, 2014, 09:32:10 PM
I don't think there are plans to implement auto in our parser anytime soon. Probably you can try Alpha's clang based code completion plugin...
As oBFusCATed says the closest is the clang based code completion (http://forums.next.codeblocks.org/index.php/topic,18785.0.html)... writing a c++ parser is close to cooling the hell, the c::b team is really happy for any improvement patch ;)
greetings
The Clang plugin does handle auto just fine. (However, note that this plugin is not production ready. It can lag, freeze, and crash if you are unlucky. I consider it functional, but use it with caution.)
I have not had time to do development on this plugin recently, but hopefully I will be able to start up again soon. Clang has a lot of potential.