logo       

Re: Manager class: msg#00044

lang.nemerle.devel

Subject: Re: Manager class



You probably need to initialize the ManagerClass object. Now as we
have the more object-oriented structure, it should be reasonably easy
to subclass ManagerClass (or use the Nemerle.Completion.Engine) and
make it perform only some chosen set of steps (like only initialize
the library references and then perform lexing) on the Run method.

I'm looking forward for defining some more methods in ManagerClass,
which could be overridden in subclasses, so we can easily enable /
disable some compilation steps or simply jump to single step.
So the idea is to always call some methods defined in ManagerClass and
avoid directly using other compiler's API.


Currently I am looking at the completion engine since it seems that it can
use that cursed Manager class. There shall be some reason why Alejandro did not
use some derived stuff (can be a historical reason), so I will not dare to move that
way before it is cleaned up. I mean when Alejandro will be able to remove that
code duplication, I will know that it would be usable for mere mortals as me... :)
What do you exactly mean with 'code duplication'? I know there's some stuff that have been moved to the Manager class, and I want to get rid of it (maybe having the compiler init directly in Manager). However, most of the things are not as in normal Manager, that's wh they remain in Engine. If you have any other suggestions, feel free to post it here, I'll try to do my best to improve the Completion Engine.
However, what do you exactly need? Lexer or parser is not available through Completion Engine, but just type tree and method completion.
A little suggestion for your refactoring work: it would be cool if you could remove all
the command line baggage from the Manager (compiler) classes and use them only in
ncc.exe. I mean: progressbar, colors, etc. So it should work that all the text IO handling
would happen interfaces and ncc.exe would use some sink to create the text from that
which you put to the console. That way for example msbuild should not parse the formatted
output not to mention the completion and future lexer/parser...
Engine has a Output rpoperty where you can directly receive the text the compiler sends. However, it still needs parsing :-(


______________________________________________ LLama Gratis a cualquier PC del Mundo. Llamadas a fijos y móviles desde 1 céntimo por minuto. http://es.voice.yahoo.com




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise