Evaluator (final PsiType operandExpressionType, Evaluator operandEvaluator) { final PsiPrimitiveType unboxedType = PsiPrimitiveType.getUnboxedType(operandExpressionType); if (unboxedType != null && !PsiTypes.booleanType().equals(unboxedType)) { operandEvaluator = new UnBoxingEvaluator(operandEvaluator); } // handle numeric promotion final PsiType _unboxedIndexType = unboxedType != null ? unboxedType : operandExpressionType; if (_unboxedIndexType instanceof PsiPrimitiveType) { final PsiType promotionType = calcUnaryNumericPromotionType((PsiPrimitiveType)_unboxedIndexType); if (promotionType != null) { operandEvaluator = createTypeCastEvaluator(operandEvaluator, promotionType); } } return operandEvaluator; }