mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
BoolUtils: make it recognize methods with negated counterparts: IDEA-199888
This commit is contained in:
+9
@@ -0,0 +1,9 @@
|
||||
import java.util.stream.Stream;
|
||||
|
||||
public class Foo {
|
||||
void m(Stream<String> s) {
|
||||
if (s.anyMatch(str -> str.equals("foo")).not<caret>) {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
import java.util.stream.Stream;
|
||||
|
||||
public class Foo {
|
||||
void m(Stream<String> s) {
|
||||
if (s.noneMatch(str -> str.equals("foo"))<caret>) {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
import java.util.Optional;
|
||||
|
||||
public class Foo {
|
||||
void m() {
|
||||
if (Optional.of("").isPresent().not<caret>) {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
import java.util.Optional;
|
||||
|
||||
public class Foo {
|
||||
void m() {
|
||||
if (Optional.of("").isEmpty()<caret>) {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user