boolean (GrIndexProperty expr) { final GrExpression qualifier = expr.getInvokedExpression(); final PsiType qualifierType = qualifier.getType(); if (qualifierType instanceof PsiClassType classType) { if (InheritanceUtil.isInheritor(qualifierType, JAVA_UTIL_LIST)) { return com.intellij.psi.util.PsiUtil.extractIterableTypeParameter(qualifierType, false) == null; } if (InheritanceUtil.isInheritor(qualifierType, JAVA_UTIL_MAP)) { return com.intellij.psi.util.PsiUtil.substituteTypeParameter(qualifierType, JAVA_UTIL_MAP, 1, false) == null; } final PsiClassType.ClassResolveResult resolveResult = classType.resolveGenerics(); GrExpression[] arguments = expr.getArgumentList().getExpressionArguments(); PsiType[] argTypes = PsiType.createArray(arguments.length); for (int i = 0; i < arguments.length; i++) { PsiType argType = arguments[i].getType(); if (argType == null) argType = TypesUtil.getJavaLangObject(expr); argTypes[i] = argType; } MethodResolverProcessor processor = new MethodResolverProcessor("getAt", expr, false, qualifierType, argTypes, PsiType.EMPTY_ARRAY); final PsiClass qClass = resolveResult.getElement(); final ResolveState state = ResolveState.initial().put(PsiSubstitutor.KEY, PsiSubstitutor.EMPTY); if (qClass != null) { qClass.processDeclarations(processor, state, null, expr); } ResolveUtil.processNonCodeMembers(qualifierType, processor, qualifier, state); final GroovyResolveResult[] candidates = processor.getCandidates(); PsiType type = null; if (candidates.length == 1) { final PsiElement element = candidates[0].getElement(); if (element instanceof PsiMethod) { type = getSmartReturnType((PsiMethod)element); } } return isRawType(type, resolveResult.getSubstitutor()); } return false; }