// "Replace with lambda" "true-preview" import java.util.function.*; class Test { public static Promise some() { return PromiseUtils.compose( new Promise(), v -> new Promise(), new Function() { @Override public Integer apply(Long result) { return 0; } }); } } class Promise {} class PromiseUtils { public static Promise compose(Promise aPromise, Function> abTransform, Function resultTransform) { return null; } }