Buggy code:
public class QualifiedNameReference extends NameReference { public char [ ] [ ] tokens ; public long [ ] sourcePositions ; public FieldBinding [ ] otherBindings ; public FieldBinding [ ] otherCodegenBindings ; int [ ] otherDepths ; public int indexOfFirstFieldBinding ; SyntheticMethodBinding syntheticWriteAccessor ; SyntheticMethodBinding [ ] syntheticReadAccessors ; public TypeBinding genericCast ; public TypeBinding [ ] otherGenericCasts ; public QualifiedNameReference ( char [ ] [ ] tokens , long [ ] positions , int sourceStart , int sourceEnd ) { } public FlowInfo analyseAssignment ( BlockScope currentScope , FlowContext flowContext , FlowInfo flowInfo , Assignment assignment , boolean isCompound ) { } public FlowInfo analyseCode ( BlockScope currentScope , FlowContext flowContext , FlowInfo flowInfo ) { } public FlowInfo analyseCode ( BlockScope currentScope , FlowContext flowContext , FlowInfo flowInfo , boolean valueRequired ) { } public TypeBinding checkFieldAccess ( BlockScope scope ) { } public void checkNPE ( BlockScope scope , FlowContext flowContext , FlowInfo flowInfo , boolean checkString ) { } public void computeConversion ( Scope scope , TypeBinding runtimeTimeType , TypeBinding compileTimeType ) { } public void generateAssignment ( BlockScope currentScope , CodeStream codeStream , Assignment assignment , boolean valueRequired ) { } public void generateCode ( BlockScope currentScope , CodeStream codeStream , boolean valueRequired ) { } public void generateCompoundAssignment ( BlockScope currentScope , CodeStream codeStream , Expression expression , int operator , int assignmentImplicitConversion , boolean valueRequired ) { } public void generatePostIncrement ( BlockScope currentScope , CodeStream codeStream , CompoundAssignment postIncrement , boolean valueRequired ) { } public FieldBinding generateReadSequence ( BlockScope currentScope , CodeStream codeStream ) { } public void generateReceiver ( CodeStream codeStream ) { } public TypeBinding [ ] genericTypeArguments ( ) { } protected FieldBinding getCodegenBinding ( int index ) { } protected TypeBinding getGenericCast ( int index ) { } public TypeBinding getOtherFieldBindings ( BlockScope scope ) { } public void manageEnclosingInstanceAccessIfNecessary ( BlockScope currentScope , FlowInfo flowInfo ) { } public void manageSyntheticAccessIfNecessary ( BlockScope currentScope , FieldBinding fieldBinding , TypeBinding lastReceiverType , int index , FlowInfo flowInfo ) { } public int nullStatus ( FlowInfo flowInfo ) { } public Constant optimizedBooleanConstant ( ) { } public TypeBinding postConversionType ( Scope scope ) { } public StringBuffer printExpression ( int indent , StringBuffer output ) { } public TypeBinding reportError ( BlockScope scope ) { } public TypeBinding resolveType ( BlockScope scope ) { this . actualReceiverType = scope . enclosingReceiverType ( ) ; this . constant = Constant . NotAConstant ; if ( ( this . codegenBinding = this . binding = scope . getBinding ( this . tokens , ( ( this . bits ) & ( ASTNode . RestrictiveFlagMASK ) ) , this , true ) ) . isValidBinding ( ) ) { switch ( ( this . bits ) & ( ASTNode . RestrictiveFlagMASK ) ) { case Binding . VARIABLE : case ( Binding . TYPE ) | ( Binding . VARIABLE ) : if ( ( this . binding ) instanceof LocalVariableBinding ) { if ( ( ! ( ( ( LocalVariableBinding ) ( this . binding ) ) . isFinal ( ) ) ) && ( ( ( this . bits ) & ( ASTNode . DepthMASK ) ) != 0 ) ) scope . problemReporter ( ) . cannotReferToNonFinalOuterLocal ( ( ( LocalVariableBinding ) ( this . binding ) ) , this ) ; this . bits &= ~ ( ASTNode . RestrictiveFlagMASK ) ; this . bits |= Binding . LOCAL ; return this . resolvedType = getOtherFieldBindings ( scope ) ; } if ( ( this . binding ) instanceof FieldBinding ) { FieldBinding fieldBinding = ( ( FieldBinding ) ( this . binding ) ) ; MethodScope methodScope = scope . methodScope ( ) ; if ( ( ( ( ( ( this . indexOfFirstFieldBinding ) == 1 ) && ( ( methodScope . enclosingSourceType ( ) ) == ( fieldBinding . original ( ) . declaringClass ) ) ) && ( ( methodScope . lastVisibleFieldID ) >= 0 ) ) && ( ( fieldBinding . id ) >= ( methodScope . lastVisibleFieldID ) ) ) && ( ( ! ( fieldBinding . isStatic ( ) ) ) || ( methodScope . isStatic ) ) ) { scope . problemReporter ( ) . forwardReference ( this , 0 , methodScope . enclosingSourceType ( ) ) ; } if ( ( ( ! ( fieldBinding . isStatic ( ) ) ) && ( ( this . indexOfFirstFieldBinding ) == 1 ) ) && ( ( scope . compilerOptions ( ) . getSeverity ( CompilerOptions . UnqualifiedFieldAccess ) ) != ( ProblemSeverities . Ignore ) ) ) { scope . problemReporter ( ) . unqualifiedFieldAccess ( this , fieldBinding ) ; } this . bits &= ~ ( ASTNode . RestrictiveFlagMASK ) ; this . bits |= Binding . FIELD ; return this . resolvedType = getOtherFieldBindings ( scope ) ; } this . bits &= ~ ( ASTNode . RestrictiveFlagMASK ) ; this . bits |= Binding . TYPE ; case Binding . TYPE : TypeBinding type = ( ( TypeBinding ) ( this . binding ) ) ; <START_BUG> type = scope . environment ( ) . convertToRawType ( type ) ; <END_BUG> return this . resolvedType = type ; } } return this . resolvedType = this . reportError ( scope ) ; } protected void setCodegenBinding ( int index , FieldBinding someCodegenBinding ) { } public void setFieldIndex ( int index ) { } protected void setGenericCast ( int index , TypeBinding someGenericCast ) { } protected void setSyntheticAccessor ( FieldBinding fieldBinding , int index , SyntheticMethodBinding syntheticAccessor ) { } public void traverse ( ASTVisitor visitor , BlockScope scope ) { } public void traverse ( ASTVisitor visitor , ClassScope scope ) { } public String unboundReferenceErrorName ( ) { } }

Fix:
type = scope . environment ( ) . convertToRawType ( type , false ) ;