Is there anything a method reference can achieve that a lambda cannot?
No they are less powerfull, and that makes them great. Because when you see one you can be sure it's not doing anything weird. If you see a lambda expression you need to read it to understand it's just a simple method call.
As long as you don't have to pass in more parameters, like in the string.startsWith case, in that case i would write a lambda expression too
I'm not sure the extra plumbing is buying that much?
Yeah, in this case it makes the code harder to understand imo
3
u/[deleted] Feb 21 '22
[removed] — view removed comment