-
Notifications
You must be signed in to change notification settings - Fork 69
Closed
Labels
priority: p3Desirable enhancement or fix. May not be included in next release.Desirable enhancement or fix. May not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Description
LambdaExpr requires a ReturnExpr to be set. And LambdaExpr.build() explicitly forbids void-typed return expressions. So it's not possible to create a lambda like this:
Runnable r1 = () -> System.out.println();
Runnable r2 = () -> {
System.out.println();
};
Runnable r3 = System.out::println;Metadata
Metadata
Assignees
Labels
priority: p3Desirable enhancement or fix. May not be included in next release.Desirable enhancement or fix. May not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.