ensure language level is retrieved from analyzed method when method hierarchy is processed

This commit is contained in:
Anna Kozlova
2015-02-12 18:52:05 +01:00
parent 8f46e89025
commit 6d0e359bbc
5 changed files with 27 additions and 10 deletions
@@ -152,7 +152,7 @@ public class HighlightMethodUtil {
: includeRealPositionInfo ? method.getReturnTypeElement().getTextRange() : TextRange.EMPTY_RANGE;
HighlightInfo highlightInfo = checkSuperMethodSignature(superMethod, superMethodSignature, superReturnType, method, methodSignature,
returnType, JavaErrorMessages.message("incompatible.return.type"),
toHighlight, languageLevel);
toHighlight, PsiUtil.getLanguageLevel(method));
if (highlightInfo != null) return highlightInfo;
}