On Mon, 22 Apr 2024 09:34:39 GMT, Per Minborg <[email protected]> wrote:
>> src/java.base/share/classes/jdk/internal/lang/stable/StableValueElement.java
>> line 116:
>>
>>> 114: public V computeIfUnset(Supplier<? extends V> supplier) {
>>> 115: // Todo: This creates a lambda
>>> 116: return computeIfUnsetShared(supplier, Supplier::get);
>>
>> Suggestion:
>>
>> return computeIfUnsetShared(supplier, supplierExtractor());
>
> Yes. This is a work in progress. I will explore using a `BiFunction` instead.
I've converted to pattern matching instead.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/18794#discussion_r1576155645