Run dotnet format whitespace

このコミットが含まれているのは:
Sergio Pedri committed 2022-10-15 09:10:18 -07:00
1 親 228d7d8b7a
コミット e94636b80c
896ファイル変更
+1511 -1511

検索条件に一致するファイルはありません

+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.ComponentModel;
namespace ComputeSharp.__Internals;
@@ -10,4 +10,4 @@ namespace ComputeSharp.__Internals;
[Obsolete("This interface is not intended to be used directly by user code")]
public interface IShader
{
}
}
@@ -1,4 +1,4 @@
using System.ComponentModel;
using System.ComponentModel;
using System.Diagnostics;
using TerraFX.Interop.Windows;
@@ -32,4 +32,4 @@ internal static class HRESULTExtensions
throw new Win32Exception(result);
}
}
}
}
@@ -53,7 +53,7 @@ public sealed class InvalidComputeContextCopyAnalyzer : DiagnosticAnalyzer
if (context.Operation is IArgumentOperation { Parameter.RefKind: RefKind.None } operation)
{
CheckCopyability(context, operation.Value);
}
}
}, OperationKind.Argument);
// Returns
@@ -358,4 +358,4 @@ public sealed class InvalidComputeContextCopyAnalyzer : DiagnosticAnalyzer
kind is (OperationKind.ObjectCreation or OperationKind.DefaultValue or OperationKind.Literal or OperationKind.Invocation) ||
(kind is (OperationKind.None or OperationKind.Invalid) && operation.Syntax is InvocationExpressionSyntax); // Workaround for https://github.com/dotnet/roslyn/issues/49751
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis;
namespace ComputeSharp.SourceGeneration.Diagnostics;
@@ -729,4 +729,4 @@ partial class DiagnosticDescriptors
isEnabledByDefault: true,
description: "The ComputeContext type cannot be copied (and values should rather be passed via ref readonly or in instead) and cannot be used as a field of value types (as it could be indirectly copied).",
helpLinkUri: "https://github.com/Sergio0694/ComputeSharp");
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
@@ -38,4 +38,4 @@ internal static class SyntaxFactoryHelper
LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(group.A)),
LiteralExpression(SyntaxKind.StringLiteralExpression, Literal(group.B))))).ToArray()));
}
}
}
@@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Text;
using ComputeSharp.__Internals;
@@ -296,4 +296,4 @@ partial class IShaderGenerator
return statements.ToImmutable();
}
}
}
}
+4 -4
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
@@ -340,7 +340,7 @@ partial class IShaderGenerator
using ImmutableArrayBuilder<(string, string)> methods = ImmutableArrayBuilder<(string, string)>.Rent();
string ? entryPoint = null;
string? entryPoint = null;
bool isSamplerUsed = false;
foreach (MethodDeclarationSyntax methodDeclaration in methodDeclarations)
@@ -455,7 +455,7 @@ partial class IShaderGenerator
{
using ImmutableArrayBuilder<(string, string)> builder = ImmutableArrayBuilder<(string, string)>.Rent();
IReadOnlyCollection <INamedTypeSymbol> invalidTypes;
IReadOnlyCollection<INamedTypeSymbol> invalidTypes;
// Process the discovered types
foreach (var type in HlslKnownTypes.GetCustomTypes(types, out invalidTypes))
@@ -789,4 +789,4 @@ partial class IShaderGenerator
hlslSourceInfo.EntryPoint;
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.__Internals;
using Microsoft.CodeAnalysis.CSharp;
@@ -94,4 +94,4 @@ partial class IShaderGenerator
return Block(blockStatements);
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System.Collections.Immutable;
using System.Collections.Immutable;
using System.Linq;
using Microsoft.CodeAnalysis;
@@ -28,4 +28,4 @@ partial class IShaderGenerator
.ToImmutableArray();
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Text;
using ComputeSharp.__Internals;
using ComputeSharp.SourceGeneration.Helpers;
@@ -251,4 +251,4 @@ partial class IShaderGenerator
return builder.ToString();
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Immutable;
using System.ComponentModel;
using System.Globalization;
@@ -276,4 +276,4 @@ partial class IShaderGenerator
}
}
}
}
}
@@ -1,4 +1,4 @@
using System.Collections.Immutable;
using System.Collections.Immutable;
using ComputeSharp.__Internals;
using ComputeSharp.SourceGeneration.Helpers;
using ComputeSharp.SourceGenerators.Models;
@@ -264,4 +264,4 @@ partial class IShaderGenerator
return statements.ToImmutable();
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
@@ -185,4 +185,4 @@ partial class IShaderGenerator
}
}
}
}
}
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Immutable;
using System.Globalization;
using ComputeSharp.__Internals;
@@ -135,4 +135,4 @@ partial class IShaderGenerator
return statements.ToImmutable();
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System.Collections.Immutable;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Helpers;
using ComputeSharp.SourceGeneration.Mappings;
using ComputeSharp.SourceGenerators.Models;
@@ -63,4 +63,4 @@ partial class IShaderGenerator
descriptors.ToImmutable());
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using ComputeSharp.SourceGeneration.Models;
using ComputeSharp.SourceGenerators.Models;
@@ -94,4 +94,4 @@ partial class IShaderGenerator
return hierarchyInfo.GetSyntax(methodDeclaration.AddAttributeLists(attributes.ToArray()));
}
}
}
+3 -3
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
@@ -136,7 +136,7 @@ public sealed partial class IShaderGenerator : IIncrementalGenerator
});
// Get the LoadDispatchData() info (hierarchy and dispatch data info)
IncrementalValuesProvider<((HierarchyInfo Hierarchy, DispatchDataInfo DispatchData) Info, bool CanUseSkipLocalsInit) > dispatchDataInfo =
IncrementalValuesProvider<((HierarchyInfo Hierarchy, DispatchDataInfo DispatchData) Info, bool CanUseSkipLocalsInit)> dispatchDataInfo =
shaderInfoWithErrors
.Select(static (item, _) => (item.Hierarchy, item.DispatchData))
.Combine(canUseSkipLocalsInit);
@@ -244,4 +244,4 @@ public sealed partial class IShaderGenerator : IIncrementalGenerator
context.AddSource($"{item.Info.Hierarchy.FilenameHint}.{nameof(LoadBytecode)}.g.cs", text);
});
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
namespace ComputeSharp.SourceGeneration.Mappings;
@@ -14,4 +14,4 @@ internal static partial class HlslKnownKeywords
knownKeywords.Add(nameof(GroupSize));
knownKeywords.Add(nameof(GridIds));
}
}
}
+1 -1
ファイルの表示
@@ -27,4 +27,4 @@ partial class HlslKnownMethods
[$"ComputeSharp.IReadOnlyNormalizedTexture3D`1.Sample({typeof(Float3).FullName})"] = null
};
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
@@ -170,4 +170,4 @@ partial class HlslKnownProperties
}
}
}
}
}
+4 -4
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using ComputeSharp.SourceGeneration.Extensions;
@@ -38,8 +38,8 @@ partial class HlslKnownTypes
{
return typeName switch
{
"ComputeSharp.ConstantBuffer`1" or
"ComputeSharp.ReadOnlyBuffer`1" or
"ComputeSharp.ConstantBuffer`1" or
"ComputeSharp.ReadOnlyBuffer`1" or
"ComputeSharp.ReadWriteBuffer`1" => true,
_ => false
};
@@ -210,4 +210,4 @@ partial class HlslKnownTypes
// Construct the HLSL type name
return $"RWTexture2D<unorm {mappedElementType}>";
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
@@ -49,4 +49,4 @@ internal sealed record DispatchDataInfo(
x.Root32BitConstantCount == y.Root32BitConstantCount;
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
@@ -35,4 +35,4 @@ internal sealed record DispatchIdInfo(ImmutableArray<string> Delegates)
return x.Delegates.SequenceEqual(y.Delegates);
}
}
}
}
+1 -1
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
@@ -45,4 +45,4 @@ internal sealed record EmbeddedBytecodeInfo(int X, int Y, int Z, ImmutableArray<
x.Bytecode.SequenceEqual(y.Bytecode);
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
@@ -139,4 +139,4 @@ internal abstract record FieldInfo
}
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
@@ -53,4 +53,4 @@ internal sealed record HlslMethodSourceInfo(
x.DependentMethods.SequenceEqual(y.DependentMethods);
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
@@ -89,4 +89,4 @@ internal sealed record HlslShaderSourceInfo(
x.Delegates.SequenceEqual(y.Delegates);
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
namespace ComputeSharp.SourceGenerators.Models;
namespace ComputeSharp.SourceGenerators.Models;
/// <summary>
/// A resource descriptor for a captured resource in a shader.
@@ -6,4 +6,4 @@
/// <param name="TypeId">The type id for the resource.</param>
/// <param name="RegisterOffset">The offset of the resource in its containing register.</param>
/// <param name="Offset">The offset of the resource descriptor in the shader root signature.</param>
internal sealed record ResourceDescriptor(int TypeId, int RegisterOffset, int Offset);
internal sealed record ResourceDescriptor(int TypeId, int RegisterOffset, int Offset);
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
@@ -62,4 +62,4 @@ internal sealed record ShaderInfo(
x.Diagnostcs.SequenceEqual(y.Diagnostcs);
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using ComputeSharp.SourceGeneration.Extensions;
@@ -40,4 +40,4 @@ internal sealed record ShaderMethodInfo(HlslMethodSourceInfo HlslMethodSource, I
x.Diagnostcs.SequenceEqual(y.Diagnostcs);
}
}
}
}
+1 -1
ファイルの表示
@@ -1,4 +1,4 @@
namespace ComputeSharp.SourceGenerators.Models;
namespace ComputeSharp.SourceGenerators.Models;
/// <summary>
/// Indicates a type of shader being processed.
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
namespace ComputeSharp.SourceGenerators.Models;
namespace ComputeSharp.SourceGenerators.Models;
/// <summary>
/// A model representing gathered info on a embedded thread ids.
@@ -7,4 +7,4 @@
/// <param name="X">The thread ids value for the X axis.</param>
/// <param name="Y">The thread ids value for the Y axis.</param>
/// <param name="Z">The thread ids value for the Z axis.</param>
internal sealed record ThreadIdsInfo(bool IsDefault, int X, int Y, int Z);
internal sealed record ThreadIdsInfo(bool IsDefault, int X, int Y, int Z);
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
@@ -188,4 +188,4 @@ public sealed partial class ShaderMethodSourceGenerator : IIncrementalGenerator
.NormalizeWhitespace(eol: "\n");
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using ComputeSharp.SourceGeneration.SyntaxRewriters;
using ComputeSharp.SourceGeneration.SyntaxRewriters;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
@@ -194,4 +194,4 @@ internal abstract class ExecuteMethodRewriter : CSharpSyntaxRewriter
return updatedNode;
}
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using ComputeSharp.SourceGeneration.Extensions;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp;
@@ -85,4 +85,4 @@ partial class ShaderSourceRewriter
{
// No special tracking is needed for DX12 compute shaders
}
}
}
+2 -2
ファイルの表示
@@ -1,4 +1,4 @@
using System;
using System;
using ComputeSharp.SourceGeneration.Extensions;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp.Syntax;
@@ -40,4 +40,4 @@ partial class StaticFieldRewriter
{
// No special tracking is needed for DX12 compute shaders
}
}
}