There are five buckets now

Remi Forax forax at univ-mlv.fr
Fri Jul 15 13:48:10 UTC 2022


> From: "John Rose" <john.r.rose at oracle.com>
> To: "Brian Goetz" <brian.goetz at oracle.com>
> Cc: "daniel smith" <daniel.smith at oracle.com>, "valhalla-spec-experts"
> <valhalla-spec-experts at openjdk.java.net>
> Sent: Wednesday, July 13, 2022 10:23:50 PM
> Subject: There are five buckets now

> FTR, I’m really happy with the user model as of this point.

> The things I like best about it are:

[...] 

>     * Object::getClass returns a predictable ref-mirror (I always wanted that)

so we have to tweak the return type of getClass() to it returns something like Class<? extends Erasure[T.ref]> and also C.val.class has to be typed Class<C>. 

> — John

Rémi 

> On 13 Jun 2022, at 16:04, Brian Goetz wrote:
>> I've done a little more shaking of this tree. It involves keeping the notion
>> that the non-identity buckets differ only in the treatment of their val
>> projection, but makes a further normalization that enables the buckets to
>> mostly collapse away.

>> "value class X" means:

>> - Instances are identity-free
>> - There are two types, X.ref (reference, nullable) and X.val (direct,
>> non-nullable)
>> - Reference types are atomic, as always
>> - X is an alias for X.ref
>>-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/valhalla-spec-experts/attachments/20220715/e1116b52/attachment.htm>


More information about the valhalla-spec-experts mailing list