Invoke "remove unnecessary final" intention in compiler modules

This commit is contained in:
Alexander Udalov
2017-04-01 00:23:37 +03:00
parent 463bbbd386
commit 34f0576135
96 changed files with 407 additions and 404 deletions
@@ -94,7 +94,7 @@ public class K2JSCompiler extends CLICompiler<K2JSCompilerArguments> {
protected ExitCode doExecute(
@NotNull K2JSCompilerArguments arguments, @NotNull CompilerConfiguration configuration, @NotNull Disposable rootDisposable
) {
final MessageCollector messageCollector = configuration.getNotNull(CLIConfigurationKeys.MESSAGE_COLLECTOR_KEY);
MessageCollector messageCollector = configuration.getNotNull(CLIConfigurationKeys.MESSAGE_COLLECTOR_KEY);
if (arguments.freeArgs.isEmpty()) {
if (arguments.version) {
@@ -242,7 +242,7 @@ public class K2JSCompiler extends CLICompiler<K2JSCompilerArguments> {
}
private static AnalyzerWithCompilerReport analyzeAndReportErrors(
@NotNull MessageCollector messageCollector, @NotNull final List<KtFile> sources, @NotNull final JsConfig config
@NotNull MessageCollector messageCollector, @NotNull List<KtFile> sources, @NotNull JsConfig config
) {
AnalyzerWithCompilerReport analyzerWithCompilerReport = new AnalyzerWithCompilerReport(messageCollector);
analyzerWithCompilerReport.analyzeAndReport(sources, new AnalyzerWithCompilerReport.Analyzer() {
@@ -148,17 +148,17 @@ public class CompileEnvironmentUtil {
@NotNull
public static List<KtFile> getKtFiles(
@NotNull final Project project,
@NotNull Project project,
@NotNull Collection<String> sourceRoots,
@NotNull CompilerConfiguration configuration,
@NotNull Function1<String, Unit> reportError
) throws IOException {
final VirtualFileSystem localFileSystem = VirtualFileManager.getInstance().getFileSystem(StandardFileSystems.FILE_PROTOCOL);
VirtualFileSystem localFileSystem = VirtualFileManager.getInstance().getFileSystem(StandardFileSystems.FILE_PROTOCOL);
final Set<VirtualFile> processedFiles = Sets.newHashSet();
final List<KtFile> result = Lists.newArrayList();
Set<VirtualFile> processedFiles = Sets.newHashSet();
List<KtFile> result = Lists.newArrayList();
final PreprocessedFileCreator virtualFileCreator = new PreprocessedFileCreator(project);
PreprocessedFileCreator virtualFileCreator = new PreprocessedFileCreator(project);
for (String sourceRootPath : sourceRoots) {
if (sourceRootPath == null) {