fix test by reporting entire local variable declaration

This commit is contained in:
Bas Leijdekkers
2017-03-22 13:27:24 +01:00
parent fdbd31cdf7
commit cc79ec29a2
@@ -269,8 +269,8 @@ public class RedundantSuppressInspectionBase extends GlobalInspectionTool {
myQuickFixes.put(key, fix);
}
PsiElement identifier;
if ((suppressedScope instanceof PsiNameIdentifierOwner)) {
identifier = ((PsiNameIdentifierOwner)documentedElement).getNameIdentifier();
if (suppressedScope instanceof PsiNameIdentifierOwner && suppressedScope instanceof PsiJavaDocumentedElement) {
identifier = ((PsiNameIdentifierOwner)suppressedScope).getNameIdentifier();
}
else {
identifier = suppressedScope;