Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign

New code completion remarks/issues

<< < (53/54) > >>

oBFusCATed:

--- Quote from: ollydbg on January 31, 2010, 02:54:04 am ---We firstly add the initial scope is "struct TestStruct", then do the AIMatch routing in this scope. Too bad that when the "local parser" parsing the local statement, both "test_1" and "test_2" will added to the "global scope namespace":

--- Code: ---{
        int test_1, test_2;
        te
    }
--- End code ---

So, when we do a AIMatch in the "strct TestStruct", we find we get the two matches: "Test()" and the member variable "test_3". At this time, we have already get the matching result size >1, so, due to the if condition, global namespace is not searched any more.

--- End quote ---

So, this is a parser bug? Can it be fixed easily?

blueshake:
It is not a bug.it can be fixed easily. :D

damur:
Hi!

I tried to use wxWidgets in Codeblocks, but Code Completion does not work correctly. And I think it's because of an #elif directive. Try this:

--- Code: ---#define CONDITION

#if defined(SOMETHING)
    #include "something.h"
#elif defined(CONDITION)
    #include "class1.h"
#endif


int main()
{
    return 0;
}
--- End code ---
class1.h is a file which is not part of your project (because else it would be parsed either way). So the file class1.h doesn't get parsed.
Interesting: replace "something.h" with "class1.h" and class1.h gets parsed, although SOMETHING is not defined.

Directives like this are used in most header files of wx base classes, for example "wx/button.h"

I'm using ubuntu9.10 and codeblocks SVN 6088. I tried also the 8.02 stable release, but it had the same bug.

blueshake:
it is not a bug.it is just not implemented yet.Be patient! Ollydbg had done a little work.it will be solved soon.

ollydbg:

--- Quote from: blueshake on February 09, 2010, 01:41:45 pm ---It is not a bug.it can be fixed easily. :D

--- End quote ---
@oBFusCATed
This is fixed in blueshakes this post: new cc search implemention.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version