Roman Kennke wrote: > Jeroen Frijters schrieb: > > Roman Kennke wrote: > >> What about > >> > >> || (l == VMClassLoader.getSystemClassLoader()) > >> > >> instead ? > > > > You shouldn't call VMClassLoader.getSystemClassLoader() (it > creates a > > new instance of the system class loader), but apart from > that comparing > > against the system class loader would work, but I'd much > rather see a > > solution that allows caching for other classes as well. > > So what should we do about it now? Should I check in the optimization > with this comparison fixed to use the system classloader for now? And > think about improving this afterwards?
Sure. > > I really would > > like to explore the option of adding a field to ClassLoader a little > > more (and hear other people's opinions about that). > > Me too. I'll cook up a proposal. Regards, Jeroen