1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-06-30 21:55:31 +02:00

Bug 145415 - Make sure we remove the symbols when files are indexed again.

This commit is contained in:
Doug Schaefer 2006-06-07 18:49:33 +00:00
parent 76a9aa7233
commit 57950488d9
2 changed files with 10 additions and 1 deletions

View file

@ -186,7 +186,7 @@ public class PDOMFullHandleDelta extends PDOMFullIndexerJob {
IASTPreprocessorIncludeStatement[] includes = ast.getIncludeDirectives();
for (int i = 0; i < includes.length; ++i) {
String incname = includes[i].getFileLocation().getFileName();
String incname = includes[i].getPath();
PDOMFile incfile = pdom.getFile(incname);
if (incfile != null)
incfile.clear();

View file

@ -65,6 +65,15 @@ public abstract class PDOMFullIndexerJob implements IPDOMIndexerTask {
pdom.acquireWriteLock();
try {
// First clear out the symbols in the includes
IASTPreprocessorIncludeStatement[] includes = ast.getIncludeDirectives();
for (int i = 0; i < includes.length; ++i) {
String incname = includes[i].getPath();
PDOMFile incfile = pdom.getFile(incname);
if (incfile != null)
incfile.clear();
}
addSymbols(tu.getLanguage(), ast);
} finally {
pdom.releaseWriteLock();