nestmates spec open issues

Remi Forax forax at
Wed Oct 25 22:33:45 UTC 2017

getClasses() throws an exception but getAnnotations() skips unavailable annotations.

that said, i'm not against throwing in this case.


----- Mail original -----
> De: "David Holmes" <david.holmes at>
> À: "Valhalla Expert Group Observers" <valhalla-spec-observers at>, "John Rose" <john.r.rose at>,
> "Brian Goetz" <Brian.Goetz at>
> Cc: "valhalla-spec-experts" <valhalla-spec-experts at>
> Envoyé: Mercredi 25 Octobre 2017 23:52:31
> Objet: Re: nestmates spec open issues

> On 26/10/2017 2:51 AM, John Rose wrote:
>> On Oct 25, 2017, at 8:39 AM, Brian Goetz <Brian.Goetz at Oracle.COM> wrote:
>>> John Rose proposed:
>>>> a) Class.getnestHost() - defaults to itself if there is a resolution error
>>> (or if there is no Nest attribute)
>> (yes)
>>>> b) Class.getNestMembers() -  returns full nest, fallback of self if any
>>>> resolution errors including it lists a nestHost that
>>>>      does not list it.
>>> For consistency with the classfile representation, this should probably omit the
>>> host class.
>> (yes, that's my preference, although the other way is not too terrible)
>>>> [editor notes:
>>>> -  full statically defined nest from classfile attribute? As distinct from full
>>>> dynamically
>>>> currently loaded nest - right?
>>> I would prefer that this return only the static members, which is consistent
>>> with the design center for reflection -- reflection over classfiles.
>> yes yes yes; the reflection should reflect what's in the class-file (or a
>> resolvable subset), not everything in the VM's knowledge
>> I like Remi's idea of scrubbing the list (of reflected nestmates) of bad actors
>> rather than clearing the list if there are *any* bad actors.
>> Reminder:  bad actors are an edge case, not a normal case.
>> Question:  what do we do in the exactly parallel case for getInnerClasses?  Do
>> we scrub bad actors?  Nullify the result?  Throw?  (Probably throw.)
> Throw.
> David
>> — John

More information about the valhalla-spec-observers mailing list