diff --git a/core/org.eclipse.cdt.core/search/ChangeLog b/core/org.eclipse.cdt.core/search/ChangeLog index df1b5ece016..32c8a098658 100644 --- a/core/org.eclipse.cdt.core/search/ChangeLog +++ b/core/org.eclipse.cdt.core/search/ChangeLog @@ -1,3 +1,7 @@ +2004-05-21 Andrew Niefer + bug 62731 - [Search] typedefs are appearing as union declarations + * search/org/eclipse/cdt/internal/core/search/matching/ClassDeclarationPattern.java + 2004-05-21 Bogdan Gheorghe bug 63320 - Search does not consider working copies Added a check to turn off indexer timer thread, if number entered is <= 0 diff --git a/core/org.eclipse.cdt.core/search/org/eclipse/cdt/internal/core/search/matching/ClassDeclarationPattern.java b/core/org.eclipse.cdt.core/search/org/eclipse/cdt/internal/core/search/matching/ClassDeclarationPattern.java index 65a5abeaa23..7610d64c5eb 100644 --- a/core/org.eclipse.cdt.core/search/org/eclipse/cdt/internal/core/search/matching/ClassDeclarationPattern.java +++ b/core/org.eclipse.cdt.core/search/org/eclipse/cdt/internal/core/search/matching/ClassDeclarationPattern.java @@ -73,18 +73,14 @@ public class ClassDeclarationPattern extends CSearchPattern { } public int matchLevel( ISourceElementCallbackDelegate node, LimitTo limit ){ - if( searchFor == TYPEDEF ){ - if( !( node instanceof IASTTypedefDeclaration ) ) - return IMPOSSIBLE_MATCH; - } else if( searchFor == ENUM ){ - if( !( node instanceof IASTEnumerationSpecifier ) ) - return IMPOSSIBLE_MATCH; - } else if ( !( node instanceof IASTClassSpecifier ) && - !( node instanceof IASTElaboratedTypeSpecifier ) && - !( node instanceof IASTTypedefDeclaration ) && - !( node instanceof IASTEnumerationSpecifier) ) + if ( !( node instanceof IASTClassSpecifier ) && + !( node instanceof IASTElaboratedTypeSpecifier ) && + !( node instanceof IASTTypedefDeclaration ) && + !( node instanceof IASTEnumerationSpecifier) ) { return IMPOSSIBLE_MATCH; + } else if( searchFor != TYPE && ((searchFor == TYPEDEF) ^ (node instanceof IASTTypedefDeclaration)) ) { + return IMPOSSIBLE_MATCH; } if( ! canAccept( limit ) )