User forums > Help
Autocomplete problem
Jenna:
I just tested again (at home on my linux machine), this time I also use a namespace for my class:
it works fine, if I declare the variable with xyz::classname* variable and have a using namespace xyz; only in the header.
It also works fine, if I have the using namespace directive in header- and cpp-file, but declare the variable without explicitely used namespace
It does not work, if I only have using namespace in the header file, and declare the variable "normally" (without explicitely used namespace).
Or in short: cc always works if I have a using namespace directive in the cpp-file or declare the variable with xyz::classname* variable.
It does not work, if I only have using namespace xyz; inside the header-file.
dgrafix:
AHAAA!
Thank you! I was "using namespaces" all over the place in my headers. I will convert everything (to do with my code) to use full names and give it a try later. I am convinced this IS the issue (as i have more or less explored everything else :shock: ).
That would explain why AC is working in the header but not the cpp file.
:D
Jenna:
For me it was enough to add using namespace xyz to the cpp-file, too.
It's less work then to use full names for every declaration (even if this would be more secure).
Please post if it works for you.
dgrafix:
Hmm, nope, although it helped a little, i have some completion now at least..
but.
I get some completion sometimes and other times it works fine one minute and stops working the next. All the files are in the same folder as the cbp file and i have "./" in the search folders for compiler.
ollydbg:
--- Quote from: dgrafix on February 21, 2009, 08:20:28 pm ---Hmm, nope, although it helped a little, i have some completion now at least..
but.
I get some completion sometimes and other times it works fine one minute and stops working the next. All the files are in the same folder as the cbp file and i have "./" in the search folders for compiler.
--- End quote ---
I think CC don't parser the code you entered before last save.
So, you could "save" your code, and let the parser do it again on your newest code.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version