Skip to content

Commit f65053d

Browse files
committed
Ran the dotnet format command on sdk.sln. Resolved any build issues it created.
1 parent 15ccb72 commit f65053d

File tree

559 files changed

+1885
-1728
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

559 files changed

+1885
-1728
lines changed

src/ApiCompat/Microsoft.DotNet.ApiCompat.Tool/SuppressableConsoleLog.cs

+3-3
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public bool LogError(Suppression suppression, string code, string message)
3131

3232
HasLoggedErrorSuppressions = true;
3333
LogError(code, message);
34-
34+
3535
return true;
3636
}
3737

@@ -40,9 +40,9 @@ public bool LogWarning(Suppression suppression, string code, string message)
4040
{
4141
if (_suppressionEngine.IsErrorSuppressed(suppression))
4242
return false;
43-
43+
4444
LogWarning(code, message);
45-
45+
4646
return true;
4747
}
4848
}

src/ApiCompat/Microsoft.DotNet.ApiCompatibility/ApiComparerSettings.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33

44
using Microsoft.CodeAnalysis;
5+
using Microsoft.DotNet.ApiCompatibility.Comparing;
56
using Microsoft.DotNet.ApiCompatibility.Mapping;
67
using Microsoft.DotNet.ApiCompatibility.Rules;
7-
using Microsoft.DotNet.ApiCompatibility.Comparing;
88
using Microsoft.DotNet.ApiSymbolExtensions.Filtering;
99

1010
namespace Microsoft.DotNet.ApiCompatibility

src/ApiCompat/Microsoft.DotNet.ApiCompatibility/Rules/AssemblyIdentityMustMatch.cs

+3-3
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ informational message to prevent user errors (i.e. wrong input to the frontend).
107107
rightMetadata.DisplayString,
108108
rightIdentity));
109109
}
110-
110+
111111
if (rightAssemblyVersion < leftAssemblyVersion)
112112
{
113113
differences.Add(CreateIdentityDifference(
@@ -139,7 +139,7 @@ informational message to prevent user errors (i.e. wrong input to the frontend).
139139
leftMetadata,
140140
rightMetadata,
141141
Resources.AssemblyPublicKeyTokenDoesNotMatch,
142-
GetStringRepresentation(leftAssemblyPublicKeyToken),
142+
GetStringRepresentation(leftAssemblyPublicKeyToken),
143143
GetStringRepresentation(rightAssemblyPublicKeyToken),
144144
leftMetadata.DisplayString,
145145
rightMetadata.DisplayString,
@@ -151,7 +151,7 @@ informational message to prevent user errors (i.e. wrong input to the frontend).
151151
leftMetadata,
152152
rightMetadata,
153153
Resources.AssemblyPublicKeyTokenDoesNotMatch,
154-
GetStringRepresentation(rightAssemblyPublicKeyToken),
154+
GetStringRepresentation(rightAssemblyPublicKeyToken),
155155
GetStringRepresentation(leftAssemblyPublicKeyToken),
156156
rightMetadata.DisplayString,
157157
leftMetadata.DisplayString,

src/ApiCompat/Microsoft.DotNet.ApiCompatibility/Rules/CannotRemoveBaseTypeOrInterface.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ private void ValidateBaseTypeNotRemoved(ITypeSymbol left, ITypeSymbol right, str
6868

6969
rightBaseType = rightBaseType.BaseType;
7070
}
71-
71+
7272
differences.Add(new CompatDifference(
7373
leftMetadata,
7474
rightMetadata,

src/ApiCompat/Microsoft.DotNet.ApiCompatibility/Runner/ApiCompatRunner.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public void ExecuteWorkItems()
6464
IApiComparer apiComparer = _apiComparerFactory.Create();
6565
apiComparer.Settings.StrictMode = workItem.Options.EnableStrictMode;
6666
apiComparer.Settings.WithReferences = runWithReferences;
67-
67+
6868

6969
// Invoke the api comparer for the work item and operate on the difference result
7070
IEnumerable<CompatDifference> differences = apiComparer.GetDifferences(leftContainerList, rightContainersList);

src/BlazorWasmSdk/Tasks/GenerateBlazorWebAssemblyBootJson50.cs

+3-1
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,9 @@ public void WriteBootJson(Stream output, string entryAssemblyName)
120120
if (IsLazyLoadedAssembly($"{fileName}.dll"))
121121
{
122122
resourceList = resourceData.lazyAssembly;
123-
} else {
123+
}
124+
else
125+
{
124126
resourceList = resourceData.pdb;
125127
}
126128
}

src/BuiltInTools/dotnet-watch/DotNetWatchOptions.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ internal sealed record DotNetWatchOptions(
3030
);
3131

3232
public bool NonInteractive { get; set; }
33-
33+
3434
public bool RunningAsTest { get => ((TestFlags & TestFlags.RunningAsTest) != TestFlags.None); }
3535

3636
private static bool IsEnvironmentSet(string key)

src/BuiltInTools/dotnet-watch/HotReload/BlazorWebAssemblyHostedDeltaApplier.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public override void Initialize(DotNetWatchContext context, CancellationToken ca
2424
_wasmApplier.Initialize(context, cancellationToken);
2525
_hostApplier.Initialize(context, cancellationToken);
2626
}
27-
27+
2828
public override async Task<ApplyStatus> Apply(DotNetWatchContext context, ImmutableArray<WatchHotReloadService.Update> updates, CancellationToken cancellationToken)
2929
{
3030
// Apply to both processes.
@@ -63,7 +63,7 @@ static void ReportStatus(IReporter reporter, ApplyStatus status, string target)
6363
}
6464
}
6565
}
66-
66+
6767
public override void Dispose()
6868
{
6969
_hostApplier.Dispose();

src/BuiltInTools/dotnet-watch/HotReload/RudeEditDialog.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public async Task EvaluateAsync(CancellationToken cancellationToken)
4040
"Do you want to restart your app - Yes (y) / No (n) / Always (a) / Never (v)?",
4141
KeyPressed,
4242
cancellationToken);
43-
43+
4444
switch (key)
4545
{
4646
case ConsoleKey.Escape:

src/BuiltInTools/dotnet-watch/Internal/ConsoleRequester.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ public async Task<ConsoleKey> GetKeyAsync(string prompt, Func<ConsoleKey, bool>
4545
Console.Out.Write($" {questionMark} ");
4646
Console.ResetColor();
4747
}
48-
48+
4949
var tcs = new TaskCompletionSource<ConsoleKey>(TaskCreationOptions.RunContinuationsAsynchronously);
5050
Console.KeyPressed += KeyPressed;
5151
try
@@ -75,7 +75,7 @@ void KeyPressed(ConsoleKeyInfo key)
7575
}
7676
}
7777
}
78-
78+
7979
void WriteLine(string message, ConsoleColor color = ConsoleColor.DarkGray)
8080
{
8181
lock (_writeLock)

src/BuiltInTools/dotnet-watch/Internal/OutputCapture.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ internal sealed class OutputCapture
1212
public IEnumerable<string> Lines => _lines;
1313
public void AddLine(string line) => _lines.Add(line);
1414
}
15-
}
15+
}

src/BuiltInTools/dotnet-watch/Internal/OutputSink.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ public OutputCapture StartCapture()
1313
return (Current = new OutputCapture());
1414
}
1515
}
16-
}
16+
}

src/Cli/Microsoft.DotNet.Cli.Sln.Internal/SlnFile.cs

+4-4
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@
2727
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2828
// THE SOFTWARE.
2929

30+
using System.Collections;
3031
using System.Collections.ObjectModel;
3132
using System.Collections.Specialized;
32-
using System.Collections;
3333
using System.Globalization;
3434
using System.Reflection;
3535
using Microsoft.DotNet.Cli.Sln.Internal.FileManipulation;
@@ -404,8 +404,8 @@ public bool IsEmpty
404404
{
405405
get
406406
{
407-
return (_properties == null || _properties.Count == 0) &&
408-
(_nestedPropertySets == null || _nestedPropertySets.All(t => t.IsEmpty)) &&
407+
return (_properties == null || _properties.Count == 0) &&
408+
(_nestedPropertySets == null || _nestedPropertySets.All(t => t.IsEmpty)) &&
409409
(_sectionLines == null || _sectionLines.Count == 0);
410410
}
411411
}
@@ -503,7 +503,7 @@ private SlnSectionType ToSectionType(int curLineNum, string s)
503503
return SlnSectionType.PostProcess;
504504
}
505505
throw new InvalidSolutionFormatException(
506-
curLineNum,
506+
curLineNum,
507507
String.Format(LocalizableStrings.InvalidSectionTypeError, s));
508508
}
509509

src/Cli/Microsoft.DotNet.Cli.Utils/AnsiConsole.cs

+12-12
Original file line numberDiff line numberDiff line change
@@ -11,29 +11,29 @@ public class AnsiConsole
1111
private AnsiConsole(TextWriter writer)
1212
{
1313
Writer = writer;
14-
14+
1515
OriginalForegroundColor = Console.ForegroundColor;
1616
_boldRecursion = ((int)OriginalForegroundColor & Light) != 0 ? 1 : 0;
1717

1818
_ansiEnabled = string.IsNullOrWhiteSpace(Environment.GetEnvironmentVariable("NO_COLOR"));
1919
}
20-
20+
2121
private int _boldRecursion;
2222

2323
public static AnsiConsole GetOutput()
2424
{
2525
return new AnsiConsole(Console.Out);
2626
}
27-
27+
2828
public static AnsiConsole GetError()
2929
{
3030
return new AnsiConsole(Console.Error);
3131
}
32-
32+
3333
public TextWriter Writer { get; }
34-
34+
3535
public ConsoleColor OriginalForegroundColor { get; }
36-
36+
3737
private void SetColor(ConsoleColor color)
3838
{
3939
if (!_ansiEnabled)
@@ -43,12 +43,12 @@ private void SetColor(ConsoleColor color)
4343

4444
int c = (int)color;
4545

46-
Console.ForegroundColor =
46+
Console.ForegroundColor =
4747
c < 0 ? color : // unknown, just use it
4848
_boldRecursion > 0 ? (ConsoleColor)(c | Light) : // ensure color is light
4949
(ConsoleColor)(c & ~Light); // ensure color is dark
5050
}
51-
51+
5252
private void SetBold(bool bold)
5353
{
5454
if (!_ansiEnabled)
@@ -61,7 +61,7 @@ private void SetBold(bool bold)
6161
{
6262
return;
6363
}
64-
64+
6565
// switches on _boldRecursion to handle boldness
6666
SetColor(Console.ForegroundColor);
6767
}
@@ -76,7 +76,7 @@ public void WriteLine(string message)
7676
public void Write(string message)
7777
{
7878
var escapeScan = 0;
79-
for (;;)
79+
for (; ; )
8080
{
8181
var escapeIndex = message.IndexOf("\x1b[", escapeScan, StringComparison.Ordinal);
8282
if (escapeIndex == -1)
@@ -95,7 +95,7 @@ public void Write(string message)
9595
{
9696
endIndex += 1;
9797
}
98-
98+
9999
var text = message.Substring(escapeScan, escapeIndex - escapeScan);
100100
Writer.Write(text);
101101
if (endIndex == message.Length)
@@ -148,7 +148,7 @@ public void Write(string message)
148148
}
149149
break;
150150
}
151-
151+
152152
escapeScan = endIndex + 1;
153153
}
154154
}

src/Cli/Microsoft.DotNet.Cli.Utils/ArgumentEscaper.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ public static class ArgumentEscaper
1515
/// <param name="args"></param>
1616
/// <returns></returns>
1717
public static string EscapeAndConcatenateArgArrayForProcessStart(IEnumerable<string> args)
18-
{
18+
{
1919
var escaped = EscapeArgArray(args);
2020
#if NET35
2121
return string.Join(" ", escaped.ToArray());
@@ -137,7 +137,7 @@ public static string EscapeSingleArg(string arg)
137137
sb.Append(arg[i]);
138138
}
139139
}
140-
140+
141141
if (needsQuotes) sb.Append("\"");
142142

143143
return sb.ToString();

src/Cli/Microsoft.DotNet.Cli.Utils/BuiltInCommand.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ public ICommand CaptureStdErr()
159159
public ICommand CaptureStdOut()
160160
{
161161
_stdOut.Capture();
162-
162+
163163
return this;
164164
}
165165

src/Cli/Microsoft.DotNet.Cli.Utils/Command.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public CommandResult Execute(Action<Process> processStarted)
4343

4444
#if DEBUG
4545
var sw = Stopwatch.StartNew();
46-
46+
4747
Reporter.Verbose.WriteLine($"> {FormatProcessInfo(_process.StartInfo)}".White());
4848
#endif
4949
using (var reaper = new ProcessReaper(_process))

src/Cli/Microsoft.DotNet.Cli.Utils/DebugHelper.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ public static void HandleDebugSwitch(ref string[] args)
1212
{
1313
if (args.Length > 0 && string.Equals("--debug", args[0], StringComparison.OrdinalIgnoreCase))
1414
{
15-
args = args.Skip(1).ToArray();
16-
WaitForDebugger();
15+
args = args.Skip(1).ToArray();
16+
WaitForDebugger();
1717
}
1818
}
1919

src/Cli/Microsoft.DotNet.Cli.Utils/EnvironmentProvider.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public IEnumerable<string> ExecutableExtensions
2222
? Environment.GetEnvironmentVariable("PATHEXT")
2323
.Split(';')
2424
.Select(e => e.ToLower().Trim('"'))
25-
: new [] { string.Empty };
25+
: new[] { string.Empty };
2626
}
2727

2828
return _executableExtensions;

src/Cli/Microsoft.DotNet.Cli.Utils/ExceptionExtensions.cs

+4-4
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ namespace Microsoft.DotNet.Cli.Utils
55
{
66
internal static class ExceptionExtensions
77
{
8-
public static TException DisplayAsError<TException>(this TException exception)
9-
where TException : Exception
8+
public static TException DisplayAsError<TException>(this TException exception)
9+
where TException : Exception
1010
{
11-
exception.Data.Add(CLI_User_Displayed_Exception, true);
12-
return exception;
11+
exception.Data.Add(CLI_User_Displayed_Exception, true);
12+
return exception;
1313
}
1414

1515
public static void ReportAsWarning(this Exception e)

src/Cli/Microsoft.DotNet.Cli.Utils/ExponentialRetry.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ public static async Task<T> ExecuteWithRetryOnFailure<T>(Func<Task<T>> action,
7272
int maxRetryCount = 3,
7373
Func<IEnumerable<Task>> timer = null)
7474
{
75-
timer = timer == null ? () => ExponentialRetry.Timer(ExponentialRetry.Intervals): timer;
75+
timer = timer == null ? () => ExponentialRetry.Timer(ExponentialRetry.Intervals) : timer;
7676
return await ExecuteAsyncWithRetry(action, result => result != null && !result.Equals(default), maxRetryCount, timer);
7777
}
7878

src/Cli/Microsoft.DotNet.Cli.Utils/Extensions/CollectionsExtensions.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ public static class CollectionsExtensions
77
{
88
public static IEnumerable<T> OrEmptyIfNull<T>(this IEnumerable<T> enumerable)
99
{
10-
return enumerable == null
10+
return enumerable == null
1111
? Enumerable.Empty<T>()
1212
: enumerable;
1313
}

src/Cli/Microsoft.DotNet.Cli.Utils/Extensions/LockFileFormatExtensions.cs

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ public static class LockFileFormatExtensions
1111
public static async Task<LockFile> ReadWithLock(this LockFileFormat subject, string path)
1212
{
1313
return await ConcurrencyUtilities.ExecuteWithFileLockedAsync(
14-
path,
14+
path,
1515
lockedToken =>
1616
{
1717
if (!File.Exists(path))
@@ -21,10 +21,10 @@ public static async Task<LockFile> ReadWithLock(this LockFileFormat subject, str
2121
string.Format(LocalizableStrings.FileNotFound, path),
2222
LocalizableStrings.ProjectNotRestoredOrRestoreFailed));
2323
}
24-
24+
2525
var lockFile = FileAccessRetrier.RetryOnFileAccessFailure(() => subject.Read(path), LocalizableStrings.CouldNotAccessAssetsFile);
2626

27-
return lockFile;
27+
return lockFile;
2828
},
2929
CancellationToken.None);
3030
}

src/Cli/Microsoft.DotNet.Cli.Utils/ForwardingAppImplementation.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -101,4 +101,4 @@ private string GetHostExeName()
101101
}
102102
}
103103

104-
#endif
104+
#endif

0 commit comments

Comments
 (0)