rename inspection/fix according to spec (IDEA-108821)

This commit is contained in:
Anna Kozlova
2013-06-12 14:57:23 +04:00
parent 5f52e35aea
commit c76af839e0
9 changed files with 11 additions and 11 deletions

View File

@@ -42,7 +42,7 @@ public class RedundantLambdaCodeBlockInspection extends BaseJavaBatchLocalInspec
@NotNull
@Override
public String getDisplayName() {
return "Lambda code block can be replaced with expression";
return "Statement lambda can be replaced with expression lambda";
}
@Override
@@ -74,7 +74,7 @@ public class RedundantLambdaCodeBlockInspection extends BaseJavaBatchLocalInspec
} else {
errorElement = body.getFirstChild();
}
holder.registerProblem(errorElement, "Lambda code block can be replaced with one line expression",
holder.registerProblem(errorElement, "Statement lambda can be replaced with expression lambda",
ProblemHighlightType.LIKE_UNUSED_SYMBOL, new ReplaceWithExprFix());
}
}
@@ -111,7 +111,7 @@ public class RedundantLambdaCodeBlockInspection extends BaseJavaBatchLocalInspec
@NotNull
@Override
public String getName() {
return "Replace with one line expression";
return "Replace with expression lambda";
}
@NotNull

View File

@@ -1,4 +1,4 @@
// "Replace with one line expression" "true"
// "Replace with expression lambda" "true"
class Test {
{
Comparable<String> c = (o) -> 0;

View File

@@ -1,4 +1,4 @@
// "Replace with one line expression" "true"
// "Replace with expression lambda" "true"
class Test {
{
Runnable c = () -> System.out.println();

View File

@@ -1,4 +1,4 @@
// "Replace with one line expression" "true"
// "Replace with expression lambda" "true"
class Test {
{
Runnable c = () -> System.out.println();

View File

@@ -1,4 +1,4 @@
// "Replace with one line expression" "true"
// "Replace with expression lambda" "true"
class Test {
{
Comparable<String> c = (o) -> {r<caret>eturn 0;};

View File

@@ -1,4 +1,4 @@
// "Replace with one line expression" "false"
// "Replace with expression lambda" "false"
class Test {
{
Runnable c = () -> <caret>{foo();};

View File

@@ -1,4 +1,4 @@
// "Replace with one line expression" "true"
// "Replace with expression lambda" "true"
class Test {
{
Runnable c = () -> <caret>{System.out.println();};

View File

@@ -1,4 +1,4 @@
// "Replace with one line expression" "true"
// "Replace with expression lambda" "true"
class Test {
{
Runnable c = () -> <caret>{{System.out.println();}};

View File

@@ -617,7 +617,7 @@
<localInspection language="JAVA" shortName="Convert2MethodRef" displayName="Lambda can be replaced with method reference"
groupName="Java language level migration aids" enabledByDefault="true" level="WARNING"
implementationClass="com.intellij.codeInspection.LambdaCanBeMethodReferenceInspection" />
<localInspection language="JAVA" shortName="CodeBlock2Expr" displayName="Lambda code block can be replaced with expression"
<localInspection language="JAVA" shortName="CodeBlock2Expr" displayName="Statement lambda can be replaced with expression lambda"
groupName="Java language level migration aids" enabledByDefault="true" level="WARNING"
implementationClass="com.intellij.codeInspection.RedundantLambdaCodeBlockInspection" />
<localInspection language="JAVA" suppressId="unchecked" shortName="SafeVarargsDetector"