Integrated: Support for null-restricted types in JShell

Jan Lahoda jlahoda at openjdk.org
Fri Jan 16 19:09:51 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;
>     }
> }

This pull request has now been integrated.

Changeset: 12ea2fa7
Author:    Jan Lahoda <jlahoda at openjdk.org>
Committer: Maurizio Cimadamore <mcimadamore at openjdk.org>
URL:       https://git.openjdk.org/valhalla/commit/12ea2fa726e6eb7b2906ac4af5a7455f1c57282a
Stats:     117 lines in 5 files changed: 73 ins; 23 del; 21 mod

Support for null-restricted types in JShell

Co-authored-by: Maurizio Cimadamore <mcimadamore at openjdk.org>
Reviewed-by: mcimadamore

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

PR: https://git.openjdk.org/valhalla/pull/1925


More information about the valhalla-dev mailing list