Hi all. Writing here to find out why autocomplete doesn't work (can't find an include file). I created a workspace with 2 projects.
In workspace settings added path to include for code complete, enabled clang code complete and now I get error that path is couldn't be finded.
* Full retag of workspace doesn't help.
* Path to libCURL include folder is correct.
Windows 7 x86 SP1 Pro, CodeLite 3.5.5377
My settings:
Code autocomplete doesn't work
-
- CodeLite Enthusiast
- Posts: 30
- Joined: Tue Apr 03, 2012 1:18 am
- Genuine User: Yes
- IDE Question: C++
- Contact:
- eranif
- CodeLite Plugin
- Posts: 6375
- Joined: Wed Feb 06, 2008 9:29 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: Code autocomplete doesn't work
You have 2 problems that I see:
1) The ctags completion paths is empty, this means that I will not be able to search for standard classes like the members of 'std', to fix this:
Copy all paths from 'clang' to the 'ctags -> Include Files' upper box
Click OK and then retag your workspace from the main menu: "workspace -> Retag workspace (full)"
The second problem that you have:
clang complains that it can not find 'curl/curl.h', this means that your project settings missing this include path.
You did added it, but to the 'code completion' section.
Unlink ctags completion, clang is an actual compiler and it will use the paths that you use in your project. In other words: if your code can compile inside codelite, then clang will work.
please read here for more information:
http://www.codelite.org/LiteEditor/ClangIntegration35
As a rule of thumb: ctags should be your default code-completion, it will rarely fails to complete (mainly when heavy macroing / templating is used)
Eran
1) The ctags completion paths is empty, this means that I will not be able to search for standard classes like the members of 'std', to fix this:
Copy all paths from 'clang' to the 'ctags -> Include Files' upper box
Click OK and then retag your workspace from the main menu: "workspace -> Retag workspace (full)"
The second problem that you have:
clang complains that it can not find 'curl/curl.h', this means that your project settings missing this include path.
You did added it, but to the 'code completion' section.
Unlink ctags completion, clang is an actual compiler and it will use the paths that you use in your project. In other words: if your code can compile inside codelite, then clang will work.
please read here for more information:
http://www.codelite.org/LiteEditor/ClangIntegration35
As a rule of thumb: ctags should be your default code-completion, it will rarely fails to complete (mainly when heavy macroing / templating is used)
Eran
Make sure you have read the HOW TO POST thread
-
- CodeLite Enthusiast
- Posts: 30
- Joined: Tue Apr 03, 2012 1:18 am
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: Code autocomplete doesn't work
I fix it as you written. Now all is ok with members of std.1) The ctags completion paths is empty, this means that I will not be able to search for standard classes like the members of 'std', to fix this:
Include paths in project's compiler settings are correct and all two projects in workspace normally build without any errors, so code complete doesn't work now. If disable clang, Ctrl+Space just do nothing and if clang is enabled I get previous error on screenshot. Nor full retag neither codelite restarting don't help me. Playing with settings about one hour... can't solve the problemclang complains that it can not find 'curl/curl.h', this means that your project settings missing this include path.
- eranif
- CodeLite Plugin
- Posts: 6375
- Joined: Wed Feb 06, 2008 9:29 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: Code autocomplete doesn't work
Have you tried installing curl into a different location (i.e. location without space in the path) ?
Eran
Eran
Make sure you have read the HOW TO POST thread
-
- CodeLite Enthusiast
- Posts: 30
- Joined: Tue Apr 03, 2012 1:18 am
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: Code autocomplete doesn't work
Yes. With path without spaces cc works well. Thanks for the help. I think you'll fix this mini-problem in next release.Have you tried installing curl into a different location (i.e. location without space in the path)?
And I should add that code complete works if clang is enabled.
- eranif
- CodeLite Plugin
- Posts: 6375
- Joined: Wed Feb 06, 2008 9:29 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: Code autocomplete doesn't work
I am pretty sure that codelite does wrap the paths in quotes, its clang that does not accept itsoMan wrote: I think you'll fix this mini-problem in next release.
Eran
Make sure you have read the HOW TO POST thread