[Nestmates] RFR: 8199309: [Nestmates] The new Class nestmate methods should have SecurityManager checks

David Holmes david.holmes at oracle.com
Tue Mar 13 11:18:12 UTC 2018


On 13/03/2018 3:48 PM, David Holmes wrote:
> On 13/03/2018 3:41 PM, John Rose wrote:
> 
>> Suggest adding an assert to getNestMembers that the host always comes 
>> first.
> 
> I can do that.

Seems I can't. If I add:

    Class<?>[] members = getNestMembers0();
+  assert(members[0] == getNestHost0()); // expected invariant from VM

then the VM crashes during the build. Seems to hit a recursive attempt 
to throw an exception from Class.<clinit> then crashes when we exhaust 
the stack. :(

I see other asserts in Class so I'm at a loss to understand why mine 
causes a problem. ??

David
-----

>> That would serve as local proof that the code which confused me is valid.
> 
> Thanks,
> David
> 


More information about the valhalla-dev mailing list