From 3c8a0f4e23858cd068f13362b0413599b717729a Mon Sep 17 00:00:00 2001 From: Alexey Kudravtsev Date: Wed, 12 Jun 2013 13:13:18 +0400 Subject: [PATCH] cleanup --- .../sameParameterValue/SameParameterValueInspection.java | 7 +++++-- .../codeInspection/unneededThrows/RedundantThrows.java | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/java/java-impl/src/com/intellij/codeInspection/sameParameterValue/SameParameterValueInspection.java b/java/java-impl/src/com/intellij/codeInspection/sameParameterValue/SameParameterValueInspection.java index 59abd75d39a5..0f756686403c 100644 --- a/java/java-impl/src/com/intellij/codeInspection/sameParameterValue/SameParameterValueInspection.java +++ b/java/java-impl/src/com/intellij/codeInspection/sameParameterValue/SameParameterValueInspection.java @@ -46,9 +46,12 @@ public class SameParameterValueInspection extends GlobalJavaInspectionTool { @Override @Nullable - public CommonProblemDescriptor[] checkElement(@NotNull RefEntity refEntity, @NotNull AnalysisScope scope, @NotNull InspectionManager manager, @NotNull GlobalInspectionContext globalContext, + public CommonProblemDescriptor[] checkElement(@NotNull RefEntity refEntity, + @NotNull AnalysisScope scope, + @NotNull InspectionManager manager, + @NotNull GlobalInspectionContext globalContext, @NotNull ProblemDescriptionsProcessor processor) { - ArrayList problems = null; + List problems = null; if (refEntity instanceof RefMethod) { final RefMethod refMethod = (RefMethod)refEntity; diff --git a/java/java-impl/src/com/intellij/codeInspection/unneededThrows/RedundantThrows.java b/java/java-impl/src/com/intellij/codeInspection/unneededThrows/RedundantThrows.java index 6b3ebe0defdd..8810af9e6bea 100644 --- a/java/java-impl/src/com/intellij/codeInspection/unneededThrows/RedundantThrows.java +++ b/java/java-impl/src/com/intellij/codeInspection/unneededThrows/RedundantThrows.java @@ -70,7 +70,7 @@ public class RedundantThrows extends GlobalJavaInspectionTool { PsiMethod psiMethod = (PsiMethod)refMethod.getElement(); PsiClassType[] throwsList = psiMethod.getThrowsList().getReferencedTypes(); PsiJavaCodeReferenceElement[] throwsRefs = psiMethod.getThrowsList().getReferenceElements(); - ArrayList problems = null; + List problems = null; final PsiManager psiManager = psiMethod.getManager(); for (int i = 0; i < throwsList.length; i++) { @@ -105,7 +105,7 @@ public class RedundantThrows extends GlobalJavaInspectionTool { } if (problems != null) { - return problems.toArray(new ProblemDescriptorBase[problems.size()]); + return problems.toArray(new CommonProblemDescriptor[problems.size()]); } }