From 9860e6bfeeff7ca5cf31eacc5a48d33a65ab750e Mon Sep 17 00:00:00 2001 From: Anna Kozlova Date: Wed, 5 Mar 2014 11:10:31 +0100 Subject: [PATCH] migration inspection: assign weak warning to produce annoyance --- .../intellij/codeInspection/StreamApiMigrationInspection.java | 4 ++-- resources/src/META-INF/IdeaPlugin.xml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/java/java-analysis-impl/src/com/intellij/codeInspection/StreamApiMigrationInspection.java b/java/java-analysis-impl/src/com/intellij/codeInspection/StreamApiMigrationInspection.java index 05306564d07d..919fb4ea28db 100644 --- a/java/java-analysis-impl/src/com/intellij/codeInspection/StreamApiMigrationInspection.java +++ b/java/java-analysis-impl/src/com/intellij/codeInspection/StreamApiMigrationInspection.java @@ -111,10 +111,10 @@ public class StreamApiMigrationInspection extends BaseJavaBatchLocalInspectionTo if (effectivelyFinal[0]) { if (isCollectCall(body)) { holder.registerProblem(iteratedValue, "Can be replaced with collect call", - ProblemHighlightType.LIKE_UNUSED_SYMBOL, new ReplaceWithCollectCallFix()); + ProblemHighlightType.GENERIC_ERROR_OR_WARNING, new ReplaceWithCollectCallFix()); } else if (!isTrivial(body, statement.getIterationParameter(), iteratedValueType)) { holder.registerProblem(iteratedValue, "Can be replaced with foreach call", - ProblemHighlightType.LIKE_UNUSED_SYMBOL, new ReplaceWithForeachCallFix()); + ProblemHighlightType.GENERIC_ERROR_OR_WARNING, new ReplaceWithForeachCallFix()); } } } diff --git a/resources/src/META-INF/IdeaPlugin.xml b/resources/src/META-INF/IdeaPlugin.xml index dbd4105722bb..ff39c265a942 100644 --- a/resources/src/META-INF/IdeaPlugin.xml +++ b/resources/src/META-INF/IdeaPlugin.xml @@ -624,7 +624,7 @@ groupName="Java language level migration aids" enabledByDefault="true" level="WARNING" implementationClass="com.intellij.codeInspection.AnonymousCanBeLambdaInspection" /> + groupName="Java language level migration aids" enabledByDefault="true" level="WEAK WARNING" implementationClass="com.intellij.codeInspection.StreamApiMigrationInspection"/>