@@ -102,7 +102,7 @@ private class NativeImageDebugCodeInfo implements DebugCodeInfo {
102102 this .compilation = compilation ;
103103 SourceManager sourceManager = ImageSingletons .lookup (SourceManager .class );
104104 try (DebugContext .Scope s = debugContext .scope ("DebugCodeInfo" , declaringClass )) {
105- fullFilePath = ImageSingletons . lookup ( SourceManager . class ) .findAndCacheSource (javaType , clazz , debugContext );
105+ fullFilePath = sourceManager .findAndCacheSource (javaType , clazz , debugContext );
106106 this .cachePath = sourceManager .getCachePathForSource (javaType );
107107 } catch (Throwable e ) {
108108 throw debugContext .handle (e );
@@ -316,9 +316,10 @@ private void computeFullFilePathAndCachePath() {
316316 if (declaringClass instanceof AnalysisType ) {
317317 declaringClass = ((AnalysisType ) declaringClass ).getWrapped ();
318318 }
319+ SourceManager sourceManager = ImageSingletons .lookup (SourceManager .class );
319320 try (DebugContext .Scope s = debugContext .scope ("DebugCodeInfo" , declaringClass )) {
320- fullFilePath = ImageSingletons . lookup ( SourceManager . class ) .findAndCacheSource (declaringClass , clazz , debugContext );
321- cachePath = ImageSingletons . lookup ( SourceManager . class ) .getCachePathForSource (declaringClass );
321+ fullFilePath = sourceManager .findAndCacheSource (declaringClass , clazz , debugContext );
322+ cachePath = sourceManager .getCachePathForSource (declaringClass );
322323 } catch (Throwable e ) {
323324 throw debugContext .handle (e );
324325 }
0 commit comments