mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
ExpressionUtils#isSimpleExpression: disable for non-final fields
This commit is contained in:
+1
-1
@@ -5,7 +5,7 @@ import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
public class Main {
|
||||
private Point field = new Point(0, 0);
|
||||
private final Point field = new Point(0, 0);
|
||||
|
||||
public Point find(List<Point> points) {
|
||||
return points.stream().filter(Objects::nonNull).findFirst().orElse(field);
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@ import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
public class Main {
|
||||
private static Point ZERO = new Point(0, 0);
|
||||
private static final Point ZERO = new Point(0, 0);
|
||||
|
||||
public static Point find(List<Point> points) {
|
||||
return points.stream().filter(Objects::nonNull).findFirst().orElse(ZERO);
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ import java.awt.*;
|
||||
import java.util.List;
|
||||
|
||||
public class Main {
|
||||
private Point field = new Point(0, 0);
|
||||
private final Point field = new Point(0, 0);
|
||||
|
||||
public Point find(List<Point> points) {
|
||||
for (Point pt : poin<caret>ts) {
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ import java.awt.*;
|
||||
import java.util.List;
|
||||
|
||||
public class Main {
|
||||
private static Point ZERO = new Point(0, 0);
|
||||
private static final Point ZERO = new Point(0, 0);
|
||||
|
||||
public static Point find(List<Point> points) {
|
||||
for (Point pt : point<caret>s) {
|
||||
|
||||
Reference in New Issue
Block a user