jigsaw now sync'ed with jdk8-b23

Mandy Chung mandy.chung at oracle.com
Wed Feb 1 13:06:58 PST 2012


On 2/1/2012 12:01 PM, Alan Bateman wrote:
>>    L483: if loader == null, should it use 
>> BootLoader.getSystemLoader() instead?
> I don't think so because in module mode we want existing code that 
> calls it with null to use the caller's class loader. I agree we need 
> to add a method to indicate if are in module mode. 

Actually I wonder if the module-aware service loader should not accept 
null loader in module mode as the service dependences are declared in 
the module-info.   I know you are thinking about adding new API for 
modules to use.  Since there are existing code that calls 
ServiceLoader.load with a null loader, using caller's loader is fine for 
now and the services work will revisit this.

Mandy



More information about the jigsaw-dev mailing list