@@ -445,45 +445,45 @@ private static Map<String, byte[]> extractTransformedClasses(BuildResult buildRe
445445
446446 private static Map <String , byte []> extractGeneratedResources (BuildResult buildResult , boolean applicationClasses ) {
447447 Map <String , byte []> data = new HashMap <>();
448+ String debugClassesDir = BootstrapDebug .debugClassesDir ();
449+ String debugSourcesDir = BootstrapDebug .debugSourcesDir ();
448450 for (GeneratedClassBuildItem i : buildResult .consumeMulti (GeneratedClassBuildItem .class )) {
449451 if (i .isApplicationClass () == applicationClasses ) {
450452 data .put (fromClassNameToResourceName (i .getName ()), i .getClassData ());
451- var debugClassesDir = BootstrapDebug .debugClassesDir ();
452453 if (debugClassesDir != null ) {
453454 try {
454455 File debugPath = new File (debugClassesDir );
455456 if (!debugPath .exists ()) {
456457 debugPath .mkdir ();
457458 }
458- File classFile = new File (debugPath , i .getName () + ".class" );
459+ File classFile = new File (debugPath , i .internalName () + ".class" );
459460 classFile .getParentFile ().mkdirs ();
460461 try (FileOutputStream classWriter = new FileOutputStream (classFile )) {
461462 classWriter .write (i .getClassData ());
462463 }
463464 log .infof ("Wrote %s" , classFile .getAbsolutePath ());
464465 } catch (Exception t ) {
465- log .errorf (t , "Failed to write debug class files %s" , i .getName ());
466+ log .errorf (t , "Failed to write debug class file for %s" , i .binaryName ());
466467 }
467468 }
468469
469- String debugSourcesDir = BootstrapDebug .debugSourcesDir ();
470470 if (debugSourcesDir != null ) {
471471 try {
472472 if (i .getSource () != null ) {
473473 File debugPath = new File (debugSourcesDir );
474474 if (!debugPath .exists ()) {
475475 debugPath .mkdir ();
476476 }
477- File sourceFile = new File (debugPath , i .getName () + ".zig" );
477+ File sourceFile = new File (debugPath , i .internalName () + ".zig" );
478478 sourceFile .getParentFile ().mkdirs ();
479479 Files .write (sourceFile .toPath (), i .getSource ().getBytes (StandardCharsets .UTF_8 ),
480480 StandardOpenOption .CREATE );
481481 log .infof ("Wrote source %s" , sourceFile .getAbsolutePath ());
482482 } else {
483- log .infof ("Source not available: %s" , i .getName ());
483+ log .infof ("Source not available: %s" , i .binaryName ());
484484 }
485485 } catch (Exception t ) {
486- log .errorf (t , "Failed to write debug source file %s" , i .getName ());
486+ log .errorf (t , "Failed to write debug source file for %s" , i .binaryName ());
487487 }
488488 }
489489 }
0 commit comments