[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [cdt-dev] weird scanner discovery behaviour
|
Hi Chris,
I don't use scanner discovery (other than to provide the built-ins), but...
2009/11/24 Chris Recoskie <recoskie@xxxxxxxxxx>:
> The problem is that any scanner info that is created after the
> ICProjectDescription has been loaded does not properly show up in the Paths
> & Symbols information, nor does it seem to be in the scanner info that is
> passed to the parser. The info on the built-ins, which is created by the
> scanner config builder during the load of the project description, is
> properly there, but the per-file info from the user's build is not there.
>
> If I close and reopen the project, the new info that was serialized
> previously to the .sc file then shows up everywhere it ought to.
>
> So basically, it seems that the ICLanguageSettingEntry data in the project
> description doesn't get updated at all except when the ICProjectDescription
> is being loaded fresh.
A lot of the contributions hang off and contribute via the
ICProjectDescriptionListener interface tweaking the description as its
loaded / changed. Having a quick poke at the code, there's the
DescriptionScannerInfoProvider and created from
ScannerInfoProviderProxy -- both of these inherit from
IScannerInfoProvider.
> Is there a way to refresh the ICLanguageSettingEntry data?
This is one of the big problems with the model. It caches everything
which is bad for memory and consistency. I had a little bit of a
battle to make it adapt to external changes to the environment.
> Failing that, is
> there a way to force the ICProjectDescription to reload? I am at my wits end
> as far as how to get the contributed scanner info to show up otherwise.
A hacky way would be to get... and set... it. This would force through
and reconcile all the external changes. You could do this at the end
of your scanner discovery build while the workspace lock is held.
There is so much broken in Scanner Discovery (and no documentation)
that fixing it is a serious challenge.
Cheers,
James