From 7f4c41fc2c6ce55f8f1b87a5516573d99a9beec0 Mon Sep 17 00:00:00 2001 From: Rob Mensching Date: Mon, 19 Apr 2021 16:12:28 -0700 Subject: Prefer IReadOnlyCollection<> or IReadOnlyList<> over IEnumerable<> Closes wixtoolset/issues#6422 --- src/WixToolset.Core/CommandLine/BuildCommand.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/WixToolset.Core/CommandLine/BuildCommand.cs') diff --git a/src/WixToolset.Core/CommandLine/BuildCommand.cs b/src/WixToolset.Core/CommandLine/BuildCommand.cs index 59aa2f1f..5f618b81 100644 --- a/src/WixToolset.Core/CommandLine/BuildCommand.cs +++ b/src/WixToolset.Core/CommandLine/BuildCommand.cs @@ -216,7 +216,7 @@ namespace WixToolset.Core.CommandLine } } - private IEnumerable CompilePhase(IDictionary preprocessorVariables, IEnumerable sourceFiles, CancellationToken cancellationToken) + private IReadOnlyList CompilePhase(IDictionary preprocessorVariables, IEnumerable sourceFiles, CancellationToken cancellationToken) { var intermediates = new List(); @@ -257,7 +257,7 @@ namespace WixToolset.Core.CommandLine return intermediates; } - private Intermediate LibraryPhase(IEnumerable intermediates, IEnumerable localizations, bool bindFiles, IEnumerable bindPaths, CancellationToken cancellationToken) + private Intermediate LibraryPhase(IReadOnlyCollection intermediates, IReadOnlyCollection localizations, bool bindFiles, IReadOnlyCollection bindPaths, CancellationToken cancellationToken) { var context = this.ServiceProvider.GetService(); context.BindFiles = bindFiles; @@ -302,7 +302,7 @@ namespace WixToolset.Core.CommandLine return linker.Link(context); } - private void BindPhase(Intermediate output, IEnumerable localizations, IEnumerable filterCultures, string cabCachePath, IEnumerable bindPaths, CancellationToken cancellationToken) + private void BindPhase(Intermediate output, IReadOnlyCollection localizations, IReadOnlyCollection filterCultures, string cabCachePath, IReadOnlyCollection bindPaths, CancellationToken cancellationToken) { var intermediateFolder = this.IntermediateFolder; if (String.IsNullOrEmpty(intermediateFolder)) @@ -405,7 +405,7 @@ namespace WixToolset.Core.CommandLine return Array.Empty(); } - private IEnumerable LoadLocalizationFiles(IEnumerable locFiles, IDictionary preprocessorVariables, CancellationToken cancellationToken) + private IReadOnlyList LoadLocalizationFiles(IEnumerable locFiles, IDictionary preprocessorVariables, CancellationToken cancellationToken) { var localizations = new List(); var parser = this.ServiceProvider.GetService(); @@ -787,7 +787,7 @@ namespace WixToolset.Core.CommandLine return Data.OutputType.Unknown; } - public IEnumerable CalculateFilterCultures() + public IReadOnlyList CalculateFilterCultures() { var result = new List(); -- cgit v1.2.3-55-g6feb