Skip to main content
summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorSergey Prigogin2011-07-21 21:27:37 -0400
committerSergey Prigogin2011-07-21 21:32:04 -0400
commit6d8a98e790f43626bab61125f3228dc96248baa9 (patch)
tree56e4199bc57450fd84cc25f6b7e92c0085062900 /core
parent48646a0cbda2b22e427a66848bf18969e32efd7b (diff)
downloadorg.eclipse.cdt-6d8a98e790f43626bab61125f3228dc96248baa9.tar.gz
org.eclipse.cdt-6d8a98e790f43626bab61125f3228dc96248baa9.tar.xz
org.eclipse.cdt-6d8a98e790f43626bab61125f3228dc96248baa9.zip
Bug 351271. Code simplification suggested by Markus Schorn.
Diffstat (limited to 'core')
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/indexer/StandaloneIndexerInputAdapter.java5
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java2
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/IndexerInputAdapter.java7
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/indexer/ProjectIndexerInputAdapter.java6
4 files changed, 1 insertions, 19 deletions
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/indexer/StandaloneIndexerInputAdapter.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/indexer/StandaloneIndexerInputAdapter.java
index 0d7612f957..3dcc9c10df 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/indexer/StandaloneIndexerInputAdapter.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/indexer/StandaloneIndexerInputAdapter.java
@@ -75,11 +75,6 @@ public class StandaloneIndexerInputAdapter extends IndexerInputAdapter {
}
@Override
- public boolean isIndexedUnconditionally(Object tu) {
- return false;
- }
-
- @Override
public boolean isIndexedUnconditionally(IIndexFileLocation ifl) {
return false;
}
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java
index 522658a6cd..52c0ed51bd 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/AbstractIndexerTask.java
@@ -485,7 +485,7 @@ public abstract class AbstractIndexerTask extends PDOMWriter {
final boolean isExcludedSource= isSourceUnit && !fIndexFilesWithoutConfiguration && !fResolver.isFileBuildConfigured(tu);
if ((isSourceUnit && !isExcludedSource) || fIndexHeadersWithoutContext != UnusedHeaderStrategy.skip ||
- fResolver.isIndexedUnconditionally(tu)) {
+ fResolver.isIndexedUnconditionally(ifl)) {
// Headers or sources required with a specific linkage
AbstractLanguage[] langs= fResolver.getLanguages(tu, fIndexHeadersWithoutContext == UnusedHeaderStrategy.useBoth);
for (AbstractLanguage lang : langs) {
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/IndexerInputAdapter.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/IndexerInputAdapter.java
index 3d52088851..26efb9e36b 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/IndexerInputAdapter.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/IndexerInputAdapter.java
@@ -56,13 +56,6 @@ public abstract class IndexerInputAdapter extends ASTFilePathResolver {
public abstract boolean isIndexedOnlyIfIncluded(Object tu);
/**
- * Checks whether the given translation unit should be indexed unconditionally.
- * @param tu An ITranslationUnit or a file location in String form.
- * @return {@code true} if the translation unit should be indexed unconditionally.
- */
- public abstract boolean isIndexedUnconditionally(Object tu);
-
- /**
* Checks whether the given file should be indexed unconditionally.
* @param ifl The Location of the file.
* @return {@code true} if the file should be indexed unconditionally.
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/indexer/ProjectIndexerInputAdapter.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/indexer/ProjectIndexerInputAdapter.java
index 37441912ec..2c71212747 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/indexer/ProjectIndexerInputAdapter.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/indexer/ProjectIndexerInputAdapter.java
@@ -243,12 +243,6 @@ public class ProjectIndexerInputAdapter extends IndexerInputAdapter {
}
@Override
- public boolean isIndexedUnconditionally(Object tuo) {
- ITranslationUnit tu= (ITranslationUnit) tuo;
- return isIndexedUnconditionally(IndexLocationFactory.getIFL(tu));
- }
-
- @Override
public boolean isIndexedUnconditionally(IIndexFileLocation ifl) {
return CCoreInternals.getPDOMManager().isFileIndexedUnconditionally(ifl);
}

Back to the top