mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-19 21:11:28 +07:00
Java: clarify quick-fix text when collapsing to noneMatch() (IDEA-309845)
GitOrigin-RevId: 0890d9367b880820af1125b0cb292916b29c238c
This commit is contained in:
committed by
intellij-monorepo-bot
parent
a781796d11
commit
1a3fa9f4f8
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2022 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2023 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.codeInspection.streamMigration;
|
||||
|
||||
import com.intellij.codeInsight.ExceptionUtil;
|
||||
@@ -503,7 +503,7 @@ public class StreamApiMigrationInspection extends AbstractBaseJavaLocalInspectio
|
||||
boolean replaceTrivialForEach) {
|
||||
boolean shouldWarn = replaceTrivialForEach || tb.hasOperations();
|
||||
if (ReferencesSearch.search(tb.getVariable(), new LocalSearchScope(statement)).findFirst() == null) {
|
||||
return new MatchMigration(shouldWarn, "anyMatch");
|
||||
return new MatchMigration(shouldWarn, "anyMatch()/noneMatch()/allMatch");
|
||||
}
|
||||
if (nonFinalVariables.isEmpty() && statement instanceof PsiExpressionStatement) {
|
||||
return new FindFirstMigration(shouldWarn);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "false"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "false"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "true-preview"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "true-preview"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "false"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "false"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Collapse loop with stream 'anyMatch()'" "false"
|
||||
// "Collapse loop with stream 'anyMatch()/noneMatch()/allMatch()'" "false"
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user