Buggy code:
public class ArrayInitializer extends Expression { public Expression [ ] expressions ; public ArrayBinding binding ; public ArrayInitializer ( ) { } public FlowInfo analyseCode ( BlockScope currentScope , FlowContext flowContext , FlowInfo flowInfo ) { } public void generateCode ( BlockScope currentScope , CodeStream codeStream , boolean valueRequired ) { } public StringBuffer printExpression ( int indent , StringBuffer output ) { } public TypeBinding resolveTypeExpecting ( BlockScope scope , TypeBinding expectedTb ) { this . constant = NotAConstant ; TypeBinding leafComponentType = expectedTb . leafComponentType ( ) ; if ( ( ( leafComponentType . isBoundParameterizedType ( ) ) || ( leafComponentType . isGenericType ( ) ) ) || ( leafComponentType . isTypeVariable ( ) ) ) { scope . problemReporter ( ) . illegalGenericArray ( leafComponentType , this ) ; } if ( expectedTb . isArrayType ( ) ) { <START_BUG> binding = ( ( ArrayBinding ) ( expectedTb ) ) ; <END_BUG> if ( ( expressions ) == null ) return binding ; TypeBinding expectedElementsTb = binding . elementsType ( ) ; if ( expectedElementsTb . isBaseType ( ) ) { for ( int i = 0 , length = expressions . length ; i < length ; i ++ ) { Expression expression = expressions [ i ] ; TypeBinding expressionTb = ( expression instanceof ArrayInitializer ) ? expression . resolveTypeExpecting ( scope , expectedElementsTb ) : expression . resolveType ( scope ) ; if ( expressionTb == null ) return null ; if ( expectedElementsTb != expressionTb ) scope . compilationUnitScope ( ) . recordTypeConversion ( expectedElementsTb , expressionTb ) ; if ( ( ( expression . isConstantValueOfTypeAssignableToType ( expressionTb , expectedElementsTb ) ) || ( BaseTypeBinding . isWidening ( expectedElementsTb . id , expressionTb . id ) ) ) || ( scope . isBoxingCompatibleWith ( expressionTb , expectedElementsTb ) ) ) { expression . computeConversion ( scope , expectedElementsTb , expressionTb ) ; } else { scope . problemReporter ( ) . typeMismatchError ( expressionTb , expectedElementsTb , expression ) ; return null ; } } } else { for ( int i = 0 , length = expressions . length ; i < length ; i ++ ) if ( ( expressions [ i ] . resolveTypeExpecting ( scope , expectedElementsTb ) ) == null ) return null ; } return binding ; } TypeBinding leafElementType = null ; int dim = 1 ; if ( ( expressions ) == null ) { leafElementType = scope . getJavaLangObject ( ) ; } else { Expression currentExpression = expressions [ 0 ] ; while ( ( currentExpression != null ) && ( currentExpression instanceof ArrayInitializer ) ) { dim ++ ; Expression [ ] subExprs = ( ( ArrayInitializer ) ( currentExpression ) ) . expressions ; if ( subExprs == null ) { leafElementType = scope . getJavaLangObject ( ) ; currentExpression = null ; break ; } currentExpression = ( ( ArrayInitializer ) ( currentExpression ) ) . expressions [ 0 ] ; } if ( currentExpression != null ) { leafElementType = currentExpression . resolveType ( scope ) ; } } if ( leafElementType != null ) { TypeBinding probableTb = scope . createArrayType ( leafElementType , dim ) ; scope . problemReporter ( ) . typeMismatchError ( probableTb , expectedTb , this ) ; } return null ; } public void traverse ( ASTVisitor visitor , BlockScope scope ) { } }

Fix:
this . resolvedType = this . binding = ( ( ArrayBinding ) ( expectedTb ) ) ;