Page 1 of 1

Code completion does not work

Posted: Fri May 13, 2011 12:47 pm
by DSP_Programmer
Hello,

[CL rev. 4798, Win7]

I've got this simple C code:

Code: Select all

typedef struct
{
    unsigned char c;
} MyStruct1;

typedef struct MyStruct2
{
    unsigned char c;
} * pMyStruct2;

int main(int argc, char **argv)
{
    MyStruct1 a;
    struct MyStruct2 b;
    pMyStruct2 p = &b;

    a.c = 0;
    b.c = 1;
    p->c = 2;

    return 0;
}
Code completion does work properly for a, but not for b and p (no code completion at all). Is this a CL parse error or is this something I do wrong?

Thanks.

Re: Code completion does not work

Posted: Fri May 20, 2011 3:59 pm
by DSP_Programmer
Hello,

as there are no responses, I simplified the code even more:

Code: Select all

typedef struct aaa
{
    unsigned char d;
}MyStruct2;

int main(int argc, char **argv)
{
    MyStruct2 b;
    b.d = 1;
    return 0;
}
For b.d there will be no code completion. This happens because the struct has got a name "aaa". If the name of the struct ("aaa" ) is removed, code completion works.

Question is still the same: Is this a CL bug?

Thanks.

Re: Code completion does not work

Posted: Fri May 20, 2011 11:13 pm
by eranif
DSP_Programmer wrote:Question is still the same: Is this a CL bug?
Yes, this is a bug.

Please open a bug report here:
http://sourceforge.net/tracker/?atid=97 ... unc=browse

Eran

Re: Code completion does not work

Posted: Sat May 21, 2011 12:31 pm
by eranif
Should be fixed in trunk now

Eran

Re: Code completion does not work

Posted: Mon May 23, 2011 10:52 am
by DSP_Programmer
Hi Eran,

thanks for the fix.