Store modification times in Declaration Data class?
svenbrauch at googlemail.com
Fri Jul 1 19:07:27 UTC 2011
I'm trying to create a Declaration type named "TypeHintedDeclaration",
which allows adding type hints to it, which will then be used for
setting a type to the declaration if it is encountered on re-parsing
(I hope that doesn't sound completely insane).
However, those type hints cannot stay with the declaration forever,
they need to be deleted when the -- whatever it might be, line of code
-- which created them is changed or removed. Thus I wanted to do the
following: Along with the type, also store the (indexed) TopContext
the type was created from and that TopContexts current
modificationRevision in the data class. Then, when accessing the type
hints, delete everything for which the modification revision does not
match the current modification revision of the file.
Do you think that can work? How would I store the modification
revisions -- the APPENDED_LIST macros give me strange errors, because
the ModificationRevision class apparently isn't meant to be stored
More information about the KDevelop-devel