RFR: Support for null-restricted types in JShell

Maurizio Cimadamore mcimadamore at openjdk.org
Fri Jan 16 16:13:07 UTC 2026


On Fri, 16 Jan 2026 15:45:02 GMT, Jan Lahoda <jlahoda at openjdk.org> wrote:

> Base on mcimadamore's idea of desugaring like:
> 
> String! str = init;
> =>
> class JShellClass {
>     public static class Holder {
>         public static String! str = init;
>     }
>     static Object do_it$() {
>         return Holder.str;
>     }
> }

Looks good -- thanks!

-------------

Marked as reviewed by mcimadamore (Committer).

PR Review: https://git.openjdk.org/valhalla/pull/1925#pullrequestreview-3671624529


More information about the valhalla-dev mailing list