Buggy code:
public class MatchLocatorParser extends Parser { MatchingNodeSet nodeSet ; PatternLocator patternLocator ; private ASTVisitor localDeclarationVisitor ; public static MatchLocatorParser createParser ( ProblemReporter problemReporter , MatchLocator locator ) { } public class NoClassNoMethodDeclarationVisitor extends ASTVisitor { public boolean visit ( ConstructorDeclaration constructorDeclaration , ClassScope scope ) { } public boolean visit ( FieldDeclaration fieldDeclaration , MethodScope scope ) { } public boolean visit ( Initializer initializer , MethodScope scope ) { } public boolean visit ( MethodDeclaration methodDeclaration , ClassScope scope ) { } } public class MethodButNoClassDeclarationVisitor extends MatchLocatorParser . NoClassNoMethodDeclarationVisitor { public boolean visit ( TypeDeclaration localTypeDeclaration , BlockScope scope ) { } } public class ClassButNoMethodDeclarationVisitor extends ASTVisitor { public boolean visit ( ConstructorDeclaration constructorDeclaration , ClassScope scope ) { } public boolean visit ( FieldDeclaration fieldDeclaration , MethodScope scope ) { } public boolean visit ( Initializer initializer , MethodScope scope ) { } public boolean visit ( TypeDeclaration memberTypeDeclaration , ClassScope scope ) { } public boolean visit ( MethodDeclaration methodDeclaration , ClassScope scope ) { } public boolean visit ( AnnotationMethodDeclaration methodDeclaration , ClassScope scope ) { } } public class ClassAndMethodDeclarationVisitor extends MatchLocatorParser . ClassButNoMethodDeclarationVisitor { public boolean visit ( TypeDeclaration localTypeDeclaration , BlockScope scope ) { } } protected MatchLocatorParser ( ProblemReporter problemReporter , MatchLocator locator ) { } public void checkComment ( ) { } protected void classInstanceCreation ( boolean alwaysQualified ) { } protected void consumeAssignment ( ) { } protected void consumeClassInstanceCreationExpressionQualifiedWithTypeArguments ( ) { } protected void consumeClassInstanceCreationExpressionWithTypeArguments ( ) { } protected void consumeExplicitConstructorInvocation ( int flag , int recFlag ) { } protected void consumeExplicitConstructorInvocationWithTypeArguments ( int flag , int recFlag ) { } protected void consumeFieldAccess ( boolean isSuperAccess ) { } protected void consumeFormalParameter ( boolean isVarArgs ) { } protected void consumeLocalVariableDeclaration ( ) { } protected void consumeMarkerAnnotation ( ) { } protected void consumeMemberValuePair ( ) { } protected void consumeMethodInvocationName ( ) { } protected void consumeMethodInvocationNameWithTypeArguments ( ) { } protected void consumeMethodInvocationPrimary ( ) { } protected void consumeMethodInvocationPrimaryWithTypeArguments ( ) { } protected void consumeMethodInvocationSuper ( ) { } protected void consumeMethodInvocationSuperWithTypeArguments ( ) { } protected void consumeNormalAnnotation ( ) { } protected void consumePrimaryNoNewArray ( ) { } protected void consumePrimaryNoNewArrayWithName ( ) { } protected void consumeSingleMemberAnnotation ( ) { } protected void consumeTypeArgument ( ) { } protected void consumeTypeParameterHeader ( ) { } protected void consumeUnaryExpression ( int op , boolean post ) { } protected TypeReference copyDims ( TypeReference typeRef , int dim ) { } protected TypeReference getTypeReference ( int dim ) { } protected NameReference getUnspecifiedReference ( ) { } protected NameReference getUnspecifiedReferenceOptimized ( ) { } public void parseBodies ( CompilationUnitDeclaration unit ) { } protected void parseBodies ( TypeDeclaration type , CompilationUnitDeclaration unit ) { FieldDeclaration [ ] fields = type . fields ; if ( fields != null ) { for ( int i = 0 ; i < ( fields . length ) ; i ++ ) { FieldDeclaration field = fields [ i ] ; if ( field instanceof Initializer ) this . parse ( ( ( Initializer ) ( field ) ) , type , unit ) ; field . traverse ( localDeclarationVisitor , null ) ; } } AbstractMethodDeclaration [ ] methods = type . methods ; if ( methods != null ) { for ( int i = 0 ; i < ( methods . length ) ; i ++ ) { AbstractMethodDeclaration method = methods [ i ] ; if ( ( method . sourceStart ) >= ( type . bodyStart ) ) { if ( method instanceof MethodDeclaration ) { MethodDeclaration methodDeclaration = ( ( MethodDeclaration ) ( method ) ) ; this . parse ( methodDeclaration , unit ) ; methodDeclaration . traverse ( localDeclarationVisitor , ( ( ClassScope ) ( null ) ) ) ; } else if ( method instanceof ConstructorDeclaration ) { ConstructorDeclaration constructorDeclaration = ( ( ConstructorDeclaration ) ( method ) ) ; <START_BUG> this . parse ( constructorDeclaration , unit ) ; <END_BUG> constructorDeclaration . traverse ( localDeclarationVisitor , ( ( ClassScope ) ( null ) ) ) ; } } else if ( method . isDefaultConstructor ( ) ) { method . parseStatements ( this , unit ) ; } } } TypeDeclaration [ ] memberTypes = type . memberTypes ; if ( memberTypes != null ) { for ( int i = 0 ; i < ( memberTypes . length ) ; i ++ ) { TypeDeclaration memberType = memberTypes [ i ] ; this . parseBodies ( memberType , unit ) ; memberType . traverse ( localDeclarationVisitor , ( ( ClassScope ) ( null ) ) ) ; } } } }

Fix:
this . parse ( constructorDeclaration , unit , false ) ;