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

Check macro usage on every identifier like token: issues and discussions

<< < (4/8) > >>

ollydbg:

--- Quote from: oBFusCATed on July 01, 2015, 09:41:14 pm ---Would you this problem affect the autocompletion, calltip and symbol browser?

--- End quote ---
Sure, yes. because the macro expansion happens in the lower tokenizer level, so that the high level parserthread only see the expanded tokens.

ollydbg:

--- Quote from: ollydbg on July 02, 2015, 02:49:19 am ---
--- Quote from: oBFusCATed on July 01, 2015, 09:41:14 pm ---Would you this problem affect the autocompletion, calltip and symbol browser?

--- End quote ---
Sure, yes. because the macro expansion happens in the lower tokenizer level, so that the high level parserthread only see the expanded tokens.

--- End quote ---
I take some time to do a simple research, I think macro expansion shouldn't be a problem.
Let me put the example code here again.

Here, I think a good code style is not use the macro definition to give a type a new name, the best way here is using typedef.
So, if we have the code:


--- Code: ---typedef unsigned char uint8;
void f(uint8 aaa);

--- End code ---
Then, the parser still see the "void f(uint8 aaa);"

I see that under MSVC, many types are actually typedef, such as "BOOL", "LPCTSTR".

BTW: I don't see much response about this patches serials :(, so this is a "ping" for further comments, thanks.

MortenMacFly:

--- Quote from: ollydbg on July 11, 2015, 04:43:41 pm ---BTW: I don't see much response about this patches serials :(, so this is a "ping" for further comments, thanks.

--- End quote ---
I didn't see there was an update. Unfortunately, all the time you apply patches in trunk this breaks your patch series here. This makes it hard to test... I'll try again with v6 from this thread (hoping its that last version and it applies well on trunk).

MortenMacFly:

--- Quote from: MortenMacFly on July 28, 2015, 01:28:48 pm ---I'll try again with v6 from this thread (hoping its that last version and it applies well on trunk).

--- End quote ---
Well... unfortunately:

--- Quote ---C:\Devel\CodeBlocks\src\plugins\codecompletion\parser\parserthread.cpp: In member function 'void ParserThread::DoParse()':
C:\Devel\CodeBlocks\src\plugins\codecompletion\parser\parserthread.cpp:803:38: error: 'tsSkipNone' was not declared in this scope
                 m_Tokenizer.SetState(tsSkipNone); // don't want to skip equals

--- End quote ---
...what to do now?

ollydbg:

--- Quote from: MortenMacFly on July 28, 2015, 01:37:47 pm ---
--- Quote from: MortenMacFly on July 28, 2015, 01:28:48 pm ---I'll try again with v6 from this thread (hoping its that last version and it applies well on trunk).

--- End quote ---
Well... unfortunately:

--- Quote ---C:\Devel\CodeBlocks\src\plugins\codecompletion\parser\parserthread.cpp: In member function 'void ParserThread::DoParse()':
C:\Devel\CodeBlocks\src\plugins\codecompletion\parser\parserthread.cpp:803:38: error: 'tsSkipNone' was not declared in this scope
                 m_Tokenizer.SetState(tsSkipNone); // don't want to skip equals

--- End quote ---
...what to do now?

--- End quote ---
I can simply rebase patches on the trunk and release the new patches, but currently I have build errors, see: Re: exchndl related patch because win32/lib folder is empty in SVN

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version