On Thu, 10 Apr 2025 12:43:30 GMT, Viktor Klang <vkl...@openjdk.org> wrote:
>> Per Minborg has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Improve docs as per comments > > src/java.base/share/classes/java/lang/StableValue.java line 582: > >> 580: static <T> Supplier<T> supplier(Supplier<? extends T> original) { >> 581: Objects.requireNonNull(original); >> 582: return StableSupplier.of(original); > > I guess if `original` is a StableSupplier then we could just return that? This is true for all the stable functions. I will take a note of this for the next round of previews. > src/java.base/share/classes/java/lang/StableValue.java line 614: > >> 612: * @throws IllegalArgumentException if the provided {@code size} is >> negative. >> 613: */ >> 614: static <R> IntFunction<R> intFunction(int size, > > Does an intFunction of size 0 make sense? it is similar to an empty list but even more useless. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/23972#discussion_r2037507369 PR Review Comment: https://git.openjdk.org/jdk/pull/23972#discussion_r2037504013