diff --git a/compiler/backend/src/org/jetbrains/jet/codegen/NamespaceCodegen.java b/compiler/backend/src/org/jetbrains/jet/codegen/NamespaceCodegen.java index 2c1511f92b2..383b6c87a35 100644 --- a/compiler/backend/src/org/jetbrains/jet/codegen/NamespaceCodegen.java +++ b/compiler/backend/src/org/jetbrains/jet/codegen/NamespaceCodegen.java @@ -77,7 +77,7 @@ public class NamespaceCodegen { } - public void generate(CompilationErrorHandler errorHandler, Progress progress) { + public void generate(CompilationErrorHandler errorHandler, final Progress progress) { ArrayList>> byFile = new ArrayList>>(); for (JetFile file : files) { @@ -96,8 +96,15 @@ public class NamespaceCodegen { for (JetFile file : files) { VirtualFile vFile = file.getVirtualFile(); try { - String path = vFile != null ? vFile.getPath() : "no_virtual_file/" + file.getName(); - if(progress != null) progress.log("For source: " + path); + final String path = vFile != null ? vFile.getPath() : "no_virtual_file/" + file.getName(); + if (progress != null) { + v.addOptionalDeclaration(new ClassBuilderOnDemand.ClassBuilderCallback() { + @Override + public void doSomething(@NotNull ClassBuilder classBuilder) { + progress.log("For source: " + path); + } + }); + } generate(file, multiFile); } catch (ProcessCanceledException e) { diff --git a/compiler/integration-tests/data/antTaskJvm/build.log.expected b/compiler/integration-tests/data/antTaskJvm/build.log.expected index 3f171971523..6dd594e38f9 100644 --- a/compiler/integration-tests/data/antTaskJvm/build.log.expected +++ b/compiler/integration-tests/data/antTaskJvm/build.log.expected @@ -2,8 +2,8 @@ OUT Buildfile: build.xml OUT OUT build: OUT [kotlinc] Compiling [[TestData]/hello.kt] => [[Temp]/hello.jar] -OUT [kotlinc] LOGGING: For source: [TestData]/hello.kt OUT [kotlinc] LOGGING: Emitting: Hello/namespace.class +OUT [kotlinc] LOGGING: For source: [TestData]/hello.kt OUT OUT BUILD SUCCESSFUL OUT Total time: [time]