New candidate JEP: 429: Extent-Local Variables (Incubator)
Remi Forax
forax at univ-mlv.fr
Fri Aug 12 16:39:51 UTC 2022
Hi all,
not a big deal but some methods do not have the correct signature, as usual there are some wildcards missing.
ExtentLocal.where() with a callable should be
<T, U> U ExtentLocal.where(ExtentLocal<T> key, T value, Callable<? extends U> op)
likewise in ExtentLocal.Carrier
<R> R call(Callable<? extends R> op)
<R> R callOrElse(Callable<? extends R> op, Function<? super Exception,? extends R> handler)
and nitpicking, because ExtentLocal.Carrier is a final class, there is no need to declare all its methods final, which change nothing in term of semantics but those final appear in the javadoc which is a kind of ugly.
regards,
Rémi
----- Original Message -----
> From: "mark reinhold" <mark.reinhold at oracle.com>
> Cc: "loom-dev" <loom-dev at openjdk.java.net>, jdk-dev at openjdk.org
> Sent: Friday, August 12, 2022 2:18:13 AM
> Subject: New candidate JEP: 429: Extent-Local Variables (Incubator)
> https://openjdk.org/jeps/429
>
> Summary: Introduce extent-local variables, which enable the sharing
> of immutable data within and across threads. They are preferred to
> thread-local variables, especially when using large numbers of virtual
> threads. This is an incubating API.
>
> - Mark
More information about the jdk-dev
mailing list