diff options
author | Sergey Prigogin | 2016-12-29 04:56:32 +0000 |
---|---|---|
committer | Sergey Prigogin | 2016-12-29 17:59:36 +0000 |
commit | 216bc162a4a40286abb2a131a62e8d65288a6050 (patch) | |
tree | 7a47ab44890547b405fb10aedeadc28252c7cf9c /core/org.eclipse.cdt.core/model | |
parent | 63d3ab9cbe4ee3aa1e81cf5ac691f5256fcb0e39 (diff) | |
download | org.eclipse.cdt-216bc162a4a40286abb2a131a62e8d65288a6050.tar.gz org.eclipse.cdt-216bc162a4a40286abb2a131a62e8d65288a6050.tar.xz org.eclipse.cdt-216bc162a4a40286abb2a131a62e8d65288a6050.zip |
Bug 509749 - Find References doesn't find a reference to a function
Change-Id: Id90a80e234638b590266a8671dd1bf13178e0f94
Diffstat (limited to 'core/org.eclipse.cdt.core/model')
-rw-r--r-- | core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/ILanguage.java | 21 | ||||
-rw-r--r-- | core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/TranslationUnit.java | 3 |
2 files changed, 9 insertions, 15 deletions
diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/ILanguage.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/ILanguage.java index 2f07b1a22fb..c177b1f6c4c 100644 --- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/ILanguage.java +++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/ILanguage.java @@ -41,7 +41,7 @@ public interface ILanguage extends IAdaptable { public final static int OPTION_SKIP_FUNCTION_BODIES= 0x1; /** - * @deprecated, has no effect. + * @deprecated, Has no effect. * @noreference This field is not intended to be referenced by clients. */ @Deprecated @@ -55,10 +55,9 @@ public interface ILanguage extends IAdaptable { public final static int OPTION_NO_IMAGE_LOCATIONS= 0x4; /** - * Option for {@link #getASTTranslationUnit(FileContent, IScannerInfo, IncludeFileContentProvider, IIndex, int, IParserLogService)} - * Marks the ast as being based on a source-file rather than a header-file. This makes a difference - * when bindings from the AST are used for searching the index, e.g. for static variables. + * @deprecated, Has no effect. */ + @Deprecated public final static int OPTION_IS_SOURCE_UNIT= 0x8; /** @@ -97,22 +96,20 @@ public interface ILanguage extends IAdaptable { public int getLinkageID(); /** - * @return the human readable name corresponding to this language, suitable for display. + * Returns the human readable name corresponding to this language, suitable for display. * @since 4.0 */ public String getName(); /** - * Construct an AST for the source code provided by <code>reader</code>. - * As an option you can supply + * Constructs an AST for the source code provided by <code>reader</code>. + * * @param content source code to be parsed. * @param scanInfo provides include paths and defined symbols. * @param fileCreator factory that provides file content for files included - * @param index (optional) index to use to lookup symbols external to the tu. - * @param options A combination of - * {@link #OPTION_SKIP_FUNCTION_BODIES}, - * {@link #OPTION_NO_IMAGE_LOCATIONS}, {@link #OPTION_IS_SOURCE_UNIT}, - * or <code>0</code>. + * @param index (optional) index to use to lookup symbols external to the translation unit. + * @param options A combination of {@link #OPTION_SKIP_FUNCTION_BODIES}, + * {@link #OPTION_NO_IMAGE_LOCATIONS}, or <code>0</code>. * @param log logger * @return an AST for the source code provided by reader. * @throws CoreException diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/TranslationUnit.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/TranslationUnit.java index 5b5f0f99b89..43418911ebd 100644 --- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/TranslationUnit.java +++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/TranslationUnit.java @@ -864,9 +864,6 @@ public class TranslationUnit extends Openable implements ITranslationUnit { if ((style & AST_PARSE_INACTIVE_CODE) != 0) { options |= ILanguage.OPTION_PARSE_INACTIVE_CODE; } - if (isSourceUnit()) { - options |= ILanguage.OPTION_IS_SOURCE_UNIT; - } final IParserLogService log; if (monitor instanceof ICanceler) { log= new ParserLogService(DebugLogConstants.PARSER, (ICanceler) monitor); |