mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-13 23:07:01 +07:00
IDEA-355026 "Trivial usage of functional expression" breaks semantics if one argument updates the variable used in another GitOrigin-RevId: e3d9374ecc427d62cee0d821473e9119ae240fc5
13 lines
379 B
Java
13 lines
379 B
Java
// "Replace method call on lambda with lambda body" "true-preview"
|
|
import java.util.function.BinaryOperator;
|
|
|
|
public class Main {
|
|
public static void main(String[] args) {
|
|
int l = 1;
|
|
int q = 2;
|
|
System.out.println(l + " " + q);
|
|
l = ((BinaryOperator<Integer>) (i, _) -> i).<caret>apply(q, q = l);
|
|
System.out.println(l + " " + q);
|
|
}
|
|
}
|