void () { Stream<String> stream = Stream.of("x"); stream.forEach(System.out::println); if (Math.random() > 0.5) { <warning descr="Stream has already been linked or consumed">stream</warning>.forEach(System.out::println); } }