misc: chore: Use collection expressions (part 2)

This commit is contained in:
KeatonTheBot
2025-03-10 21:32:01 -05:00
parent c923c0043a
commit 340ec79e9f
176 changed files with 308 additions and 308 deletions
@@ -41,7 +41,7 @@ namespace Ryujinx.Graphics.Shader.StructuredIr
Type = type;
Condition = condition;
_nodes = new LinkedList<IAstNode>();
_nodes = [];
}
public void Add(IAstNode node)
@@ -17,8 +17,8 @@ namespace Ryujinx.Graphics.Shader.StructuredIr
private AstOperand()
{
Defs = new HashSet<IAstNode>();
Uses = new HashSet<IAstNode>();
Defs = [];
Uses = [];
VarType = AggregateType.S32;
}
@@ -429,7 +429,7 @@ namespace Ryujinx.Graphics.Shader.StructuredIr
{
AstBlock block = bottom;
List<AstBlock> path = new();
List<AstBlock> path = [];
while (block != top)
{
@@ -29,7 +29,7 @@ namespace Ryujinx.Graphics.Shader.StructuredIr
InArguments = inArguments;
OutArguments = outArguments;
Locals = new HashSet<AstOperand>();
Locals = [];
}
public AggregateType GetArgumentType(int index)
@@ -343,7 +343,7 @@ namespace Ryujinx.Graphics.Shader.StructuredIr
private static AggregateType GetVarTypeFromUses(Operand dest)
{
HashSet<Operand> visited = new();
HashSet<Operand> visited = [];
Queue<Operand> pending = new();
@@ -12,9 +12,9 @@ namespace Ryujinx.Graphics.Shader.StructuredIr
public StructuredProgramInfo()
{
Functions = new List<StructuredFunction>();
Functions = [];
IoDefinitions = new HashSet<IoDefinition>();
IoDefinitions = [];
}
}
}