News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

Code completion and Symbols Browser problem

Started by BrianSidebotham, September 05, 2006, 06:13:40 PM

Previous topic - Next topic

BrianSidebotham

Hi All,

There seems to be a funny in the symbols browser which affects the code completion.

Take the following piece of code:


typedef struct strType
    {
        unsigned char El1;
        unsigned char El2;
        unsigned char El3;
    } New_t;

New_t NewTypeStructure;

int main(void)
{
    NewTypeStructure
}


This gives the symbol NewTypeStructure under the Global Variables section of the symbols browser, and code completion gives it as a suggestion as I type. However, it will not show me the structures elements, or show me the New_t type as a structure in the symbols browser.

Now take the following piece of code:


struct strType
    {
        unsigned char El1;
        unsigned char El2;
        unsigned char El3;
    } NewTypeStructure;

int main(void)
{
    NewT
}


In this example, the symbols browser adds strType to the symbols browser, and you can see the elements of the structure in the symbols browser. However, NewTypeStructure is not offered by code completion any more and the same applies that auto completion does not offer the elements for completion.

Interestingly, NewTypeStructure in the last example does not get added to the Global Variables, even though it is now a global variable with structure strType.

I'm coding for an embedded target, so I'm completely coding in C. Maybe there's something to click in order to get the symbols browser to scan code for c structures?

This is with the 1.0 Rev 2946 version of c::b

Best Regards,

Brian.

mandrav

C-style structs and typedefs are not yet supported...
Be patient!
This bug will be fixed soon...

BrianSidebotham

Cool. Is this a limitation of C::B? or a different project? (Sorry, I don't know what is used to generate the symbols list)

I presume this is already a development task and doesn't need to be added as a feature request?

Brian.

mandrav

Quote from: BrianSidebotham on September 07, 2006, 12:30:01 PM
Is this a limitation of C::B? or a different project? (Sorry, I don't know what is used to generate the symbols list)

We are using a hand-crafted tokenizer/parser.
And yes, it is under development.
Be patient!
This bug will be fixed soon...