hide "static methods should have body" message for interface methods < 1.8 (DEA-129765)

This commit is contained in:
Anna Kozlova
2014-09-12 16:24:24 +04:00
parent 3915baf2fc
commit aa6d50ddc5
@@ -1026,7 +1026,7 @@ public class HighlightMethodUtil {
description = JavaErrorMessages.message("extension.method.should.have.a.body");
additionalFixes.add(QUICK_FIX_FACTORY.createAddMethodBodyFix(method));
}
else if (isInterface && isStatic) {
else if (isInterface && isStatic && languageLevel.isAtLeast(LanguageLevel.JDK_1_8)) {
description = "Static methods in interfaces should have a body";
}
}