RefObject and ValObject

forax at forax at
Mon Apr 15 20:43:38 UTC 2019

> De: "Maurizio Cimadamore" <maurizio.cimadamore at>
> À: "Brian Goetz" <brian.goetz at>, "Remi Forax" <forax at>
> Cc: "valhalla-spec-experts" <valhalla-spec-experts at>
> Envoyé: Lundi 15 Avril 2019 22:23:25
> Objet: Re: RefObject and ValObject

> Maybe (Remi correct me if I'm wrong), the problem Remi was referring to is that
> we also have existing generic declarations like <T extends Object> which, in
> the new world, will mean either VALUE or REFERENCE. I think this is a
> consequence of the choice (1) I described in my email - e.g. reinterpret Object
> in type position as TOP_TYPE.

> Maurizio
yes ! 
all generics will suddenly accept value types. 


> On 15/04/2019 19:00, Brian Goetz wrote:

>>> It's not a minor change, and all code that uses a type parameter that have
>>> Object as bound will become ambiguous.

>> I don’t think so. You can’t say

>> new T()

>> when T is bounded at Object (or anything, for that matter.).

>> What ambiguity are you afraid of here?

More information about the valhalla-spec-observers mailing list