Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [Dltk-dev] calls to parse method of source parser

Hi Sebastian,

This is normal situation and DLTK has caching for AST's implemented.

With default implementations parser are used from many places:
1. To build structure model
2. To build index
3. for folding in editors.
4. semantic highlighting.
5. selection/completion
.. etc.

To get ModuleDeclaration we call for org.eclipse.dltk.core.SourceParserUtil.parse(ISourceModule, IProblemReporter) methods.
Please check to use same method to retrieve AST. Then parsing will be performed only one time, per source module change.

Best regards,
Andrei Sobolev.

21.09.2011 22:56, Sebastian Rheinnecker пишет:
Hi,

whilst working on the other problem ;) i have another question:
Everytime the parser should be called (after changes in the editor or
at startup and so on) the parse Method is called _twice_! You can see
that from prints to the console. Is this supposed to be? Otherwise
this would be a hard hit to the overall performance.

thanks in advance,


Back to the top