Fix forcing java to compile if kotlin classes are compiled
This commit is contained in:
+2
-4
@@ -328,6 +328,8 @@ internal class IncrementalJvmCompilerRunner(
|
|||||||
|
|
||||||
val compilerOutput = compileChanged(listOf(targetId), sourcesToCompile.toSet(), args, { caches.incrementalCache }, lookupTracker, messageCollector)
|
val compilerOutput = compileChanged(listOf(targetId), sourcesToCompile.toSet(), args, { caches.incrementalCache }, lookupTracker, messageCollector)
|
||||||
exitCode = compilerOutput.exitCode
|
exitCode = compilerOutput.exitCode
|
||||||
|
val generatedClassFiles = compilerOutput.generatedFiles
|
||||||
|
anyClassesCompiled = anyClassesCompiled || generatedClassFiles.isNotEmpty() || removedKotlinSources.isNotEmpty()
|
||||||
|
|
||||||
if (exitCode == ExitCode.OK) {
|
if (exitCode == ExitCode.OK) {
|
||||||
dirtySourcesSinceLastTimeFile.delete()
|
dirtySourcesSinceLastTimeFile.delete()
|
||||||
@@ -337,8 +339,6 @@ internal class IncrementalJvmCompilerRunner(
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
val generatedClassFiles = compilerOutput.generatedFiles
|
|
||||||
|
|
||||||
if (compilationMode is CompilationMode.Incremental) {
|
if (compilationMode is CompilationMode.Incremental) {
|
||||||
val dirtySourcesSet = dirtySources.toHashSet()
|
val dirtySourcesSet = dirtySources.toHashSet()
|
||||||
val additionalDirtyFiles = additionalDirtyFiles(caches, generatedClassFiles).filter { it !in dirtySourcesSet }
|
val additionalDirtyFiles = additionalDirtyFiles(caches, generatedClassFiles).filter { it !in dirtySourcesSet }
|
||||||
@@ -391,8 +391,6 @@ internal class IncrementalJvmCompilerRunner(
|
|||||||
|
|
||||||
buildDirtyLookupSymbols.addAll(dirtyLookupSymbols)
|
buildDirtyLookupSymbols.addAll(dirtyLookupSymbols)
|
||||||
buildDirtyFqNames.addAll(dirtyClassFqNames)
|
buildDirtyFqNames.addAll(dirtyClassFqNames)
|
||||||
|
|
||||||
anyClassesCompiled = anyClassesCompiled || generatedClassFiles.isNotEmpty() || removedKotlinSources.isNotEmpty()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (exitCode == ExitCode.OK && compilationMode is CompilationMode.Incremental) {
|
if (exitCode == ExitCode.OK && compilationMode is CompilationMode.Incremental) {
|
||||||
|
|||||||
Reference in New Issue
Block a user