Considering..
List<Foo> copy(List<Foo> foos) { return foos .stream() .map(foo -> new Foo(foo)) .collect(Collectors.toList()); }
IntelliJ IDEA 2016.1.1 reports that new Foo(foo) "can be replaced with a method reference."
I know the Foo::new syntax for the no-arg constructor, but I donβt see how I could pass foo as an argument. Of course, I missed something.
source share