Skip to content

Commit

Permalink
Use faster JavaSourceSet.build() overload
Browse files Browse the repository at this point in the history
  • Loading branch information
sambsnyd committed Aug 8, 2024
1 parent 9992c58 commit 60166a4
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -833,7 +833,7 @@ public Stream<SourceFile> parse(Project subproject, Set<Path> alreadyParsed, Exe
}
}

JavaSourceSet sourceSetProvenance = JavaSourceSet.build(sourceSet.getName(), dependencyPaths, javaTypeCache, false);
JavaSourceSet sourceSetProvenance = JavaSourceSet.build(sourceSet.getName(), dependencyPaths);
sourceFileStream = sourceFileStream.concat(sourceSetSourceFiles.map(addProvenance(sourceSetProvenance)), sourceSetSize);
// Some source sets get misconfigured to have the same directories as other source sets
// Prevent files which appear in multiple source sets from being parsed more than once
Expand Down Expand Up @@ -1137,7 +1137,7 @@ private SourceFileStream parseMultiplatformKotlinProject(Project subproject, Col
}
return cu;
}).filter(Objects::nonNull);
JavaSourceSet sourceSetProvenance = JavaSourceSet.build(sourceSetName, dependencyPaths, javaTypeCache, false);
JavaSourceSet sourceSetProvenance = JavaSourceSet.build(sourceSetName, dependencyPaths);

sourceFileStream = sourceFileStream.concat(cus.map(addProvenance(sourceSetProvenance)), kotlinPaths.size());
logger.info("Scanned {} Kotlin sources in {}/{}", kotlinPaths.size(), subproject.getPath(), kotlinDirectorySet.getName());
Expand Down

0 comments on commit 60166a4

Please sign in to comment.