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

Add some comments to CC's code

<< < (2/2)

ollydbg:
If I remember, the Image related code was located in parser class. somehow, Loaden move that code to nativeparser. (right?)


--- Quote ---Originally, the concept was that "nativeparser" does know nothing about the language (i.e. C++), so that's why this part is in the language-specific parser. nativepasrer was supposed to just offer the interface / overlay to C::B. As is cannot know what items how to mark, partially the UI elements are also in the parser.

However, this is surely debatable, and in fact this concept is broken anyways IMHO.
--- End quote ---
agree. I strongly suggest we still need a clean class design, I'm not satisfied with the current one. There are two many things mixing.

Especially the "one parser for whole workplace" option make the nativeparser/parser class hard to comprehend.

I would think:

--- Code: ---               
               ParserBase
               |             \
              |                \
ParserForSingleProject  ParserForMultiplyProjects

--- End code ---

Nativeparser should know nothing about the lower level Parser.

ollydbg:
Nativeparser class do much things which should not belong to.
such as "generate code suggesting list", this is also language specific, should lower to some other class like "c++ parser class".

I think the nativeparser should only manage different parser classes.

Also, CodeCompletion class has a lot of code doing the "ToolBar GUI control"(such as jump from function bodies...) but It shouldn't be there, either the toolbar related code can be grouped out to make a new class, or it should be lowered to a language specific class.

ollydbg:
Patch to fix typos in CC's source code. Many thanks to the spell checker plugin!!!

Navigation

[0] Message Index

[*] Previous page

Go to full version