Remove compiledWithErrors param
`updateIncrementalCache` is not called when code does not compile.
This commit is contained in:
@@ -78,8 +78,7 @@ fun makeCompileServices(
|
||||
|
||||
fun updateIncrementalCache(
|
||||
generatedFiles: List<GeneratedFile<*>>,
|
||||
cache: IncrementalCacheImpl,
|
||||
compiledWithErrors: Boolean
|
||||
cache: IncrementalCacheImpl
|
||||
): CompilationResult {
|
||||
var changesInfo = CompilationResult.NO_CHANGES
|
||||
for (generatedFile in generatedFiles) {
|
||||
@@ -89,10 +88,8 @@ fun updateIncrementalCache(
|
||||
}
|
||||
}
|
||||
|
||||
if (!compiledWithErrors) {
|
||||
val newChangesInfo = cache.clearCacheForRemovedClasses()
|
||||
changesInfo += newChangesInfo
|
||||
}
|
||||
val newChangesInfo = cache.clearCacheForRemovedClasses()
|
||||
changesInfo += newChangesInfo
|
||||
|
||||
return changesInfo
|
||||
}
|
||||
|
||||
+1
-1
@@ -318,7 +318,7 @@ class IncrementalJvmCompilerRunner(
|
||||
|
||||
allGeneratedFiles.addAll(generatedFiles)
|
||||
caches.inputsCache.registerOutputForSourceFiles(generatedFiles)
|
||||
val compilationResult = updateIncrementalCache(generatedFiles, caches.jvmCache, compiledWithErrors = exitCode != ExitCode.OK)
|
||||
val compilationResult = updateIncrementalCache(generatedFiles, caches.platformCache)
|
||||
|
||||
caches.lookupCache.update(lookupTracker, sourcesToCompile, removedKotlinSources)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user