Prefer using collection expressions with implicit object creation when the type is clear

This commit is contained in:
Marco Carvalho
2024-12-27 13:23:31 -03:00
parent 850df38f1e
commit 57d1486da9
510 changed files with 6022 additions and 6212 deletions

View File

@@ -75,8 +75,8 @@ namespace Ryujinx.Graphics.Shader.CodeGen.Msl
context.AppendLine();
DeclareOutputAttributes(context, info.IoDefinitions.Where(x => x.StorageKind == StorageKind.Output));
context.AppendLine();
DeclareBufferStructures(context, context.Properties.ConstantBuffers.Values.OrderBy(x => x.Binding).ToArray(), true, fsi);
DeclareBufferStructures(context, context.Properties.StorageBuffers.Values.OrderBy(x => x.Binding).ToArray(), false, fsi);
DeclareBufferStructures(context, [.. context.Properties.ConstantBuffers.Values.OrderBy(x => x.Binding)], true, fsi);
DeclareBufferStructures(context, [.. context.Properties.StorageBuffers.Values.OrderBy(x => x.Binding)], false, fsi);
// We need to declare each set as a new struct
var textureDefinitions = context.Properties.Textures.Values