Files
openide/java/java-tests/testData/codeInsight/daemonCodeAnalyzer/quickFix/makeVarEffectivelyFinal/beforeStreamFind.java
Tagir Valeev d9193529e2 [java-inspections] MakeVarEffectivelyFinalFix: stream API fixer
GitOrigin-RevId: e6f1c6e2d80af6332bae642391ca4b6113aa12ed
2022-10-06 15:55:11 +00:00

15 lines
326 B
Java

// "Make 's' effectively final using stream API" "true-preview"
import java.util.*;
class Test {
public static void main(String[] args) {
String s = null;
for (String arg : args) {
if (arg.length() > 5) {
s = arg;
break;
}
}
Runnable r = () -> System.out.println(<caret>s);
}
}