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

Some annoying symbols-browser issues

(1/6) > >>

Jenna:
One issue I get on windows xp and on my debian system (gcc 4.5 on windows amd 4.6 on linux) is, that neither the PARSER_START not the PARSER_END event is caught by the appropriate event-handlers.
Refreshing the symbols-browser tree manually works, switching between the View (e.g. Everything and workspace) works also.
The event is sent correctly if I debug C::B, but as I wrote it is never caught.

Another thing, is that switching between workspace- and project-view does not show all symbols. In both views I only get the symbols from the project, that was active when opening the workspace (two projects, one parser per project or one parser per workspace).

As third: I always see some boost-defines and most likely some of the other high-priority headers (former up-front) in the symbols-browser, even if I do not include these headers any of my projects.

ollydbg:

--- Quote from: jens on August 01, 2011, 10:20:29 pm ---One issue I get on windows xp and on my debian system (gcc 4.5 on windows amd 4.6 on linux) is, that neither the PARSER_START not the PARSER_END event is caught by the appropriate event-handlers.

--- End quote ---
I'm testing this issue on Windows XP and rev 7289.
It seems all the PARSER_START and PARSER_END works fine.
The flow is something like:(when a project is loaded)
1, send PARSER_START
2, NativeParser::OnParserStart() been called
3, CodeCompletion::OnParserStart() been called
4, send PARSER_END
5, NativeParser::OnParserEnd() been called
6, CodeCompletion::OnParserEnd() been called.


--- Quote from: jens on August 01, 2011, 10:20:29 pm ---As third: I always see some boost-defines and most likely some of the other high-priority headers (former up-front) in the symbols-browser, even if I do not include these headers any of my projects.

--- End quote ---
The high-priority headers were predefined by Codecompletion plugin, and they were searched and parsed before parsing any actual files in your projects. This behavior is used to handle some predefined macro definition in those high-priority headers. So, even you did not include those files in your projects, they were still be parsed, thus this issue you complain happens.
I think you can simply change these high-priority headers in Codecompletions options dialog. :D

Loaden:

--- Quote from: ollydbg on August 02, 2011, 04:08:13 am ---
--- Quote from: jens on August 01, 2011, 10:20:29 pm ---As third: I always see some boost-defines and most likely some of the other high-priority headers (former up-front) in the symbols-browser, even if I do not include these headers any of my projects.

--- End quote ---
The high-priority headers were predefined by Codecompletion plugin, and they were searched and parsed before parsing any actual files in your projects. This behavior is used to handle some predefined macro definition in those high-priority headers. So, even you did not include those files in your projects, they were still be parsed, thus this issue you complain happens.
I think you can simply change these high-priority headers in Codecompletions options dialog. :D

--- End quote ---
Maybe we can put it into "Project > Properties > C/C++ Parser options".
So that each project can be set to different high-priority headers.

MortenMacFly:

--- Quote from: Loaden on August 02, 2011, 06:53:13 am ---Maybe we can put it into "Project > Properties > C/C++ Parser options".
So that each project can be set to different high-priority headers.

--- End quote ---
But then, people won't do it and effectively loose this feature. I think it' OK to have them in one place and maybe spoil the symbol table with a little useless information. In the end it doesn't consume too much memory.

BTW: Jens, I cannot reproduce on Windows XP. Could you provide simple steps / a project to reproduce? Do you see in the debug log the message "NativeParser received parser end event" and "CodeCompletion received parser end event"? I see them whatever parsr configuration I use...?!

Jenna:
@ollydbg:
I know how the event-handling should work, and the appropriate calls to PostParserEvent are made, but the events are never caught.
Here is the debug-log after creating a new console-project with the wizard, before creating I cleaned the log:

--- Code: ---4 user templates loaded
Project's base path: /tmp/test/
Project's common toplevel path: /tmp/test/
Caching GCC dir: /usr/include/c++/4.6
Caching GCC dir: /usr/include/c++/4.6/x86_64-linux-gnu
Caching GCC dir: /usr/include/c++/4.6/backward
Caching GCC dir: /usr/lib/x86_64-linux-gnu/gcc/x86_64-linux-gnu/4.6.1/include
Caching GCC dir: /usr/lib/x86_64-linux-gnu/gcc/x86_64-linux-gnu/4.6.1/include-fixed
Caching GCC dir: /usr/include/x86_64-linux-gnu
Caching GCC dir: /usr/include
Passing list of files to batch-parser.
Header to parse with priority: '/usr/include/c++/4.6/cstddef'
Header to parse with priority: '/usr/include/boost/config.hpp'
Header to parse with priority: '/usr/include/boost/filesystem/config.hpp'
Add 3 priority parsing file(s) for project 'test'...
Added 1 file(s) for project 'test' to batch-parser...
Create new parser for project 'test'

--- End code ---

Of course nothing happens in the symbols-browser, but after refreshing the tree, evrything is there.

@MortenMacFly:
I can not test on XP at the moment, not at work until next week (holidays  :D ), but will test it on win7 later.

About littering the symbols-browser with boost- (and other) defines:
it's a minor issue, but I would prefer to see only stuff, that is in the scope of my application.
Is there no information about the reachable header-files to filter these defines ?

By the way the autocompletion does not work for any defines after an #ifdef, but on a blank line.

Navigation

[0] Message Index

[#] Next page

Go to full version