mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-07-30 17:49:57 -06:00
misc: chore: Use collection expressions in HLE project
This commit is contained in:
@ -87,11 +87,11 @@ namespace Ryujinx.HLE.HOS
|
||||
|
||||
public ModCache()
|
||||
{
|
||||
RomfsContainers = new List<Mod<FileInfo>>();
|
||||
ExefsContainers = new List<Mod<FileInfo>>();
|
||||
RomfsDirs = new List<Mod<DirectoryInfo>>();
|
||||
ExefsDirs = new List<Mod<DirectoryInfo>>();
|
||||
Cheats = new List<Cheat>();
|
||||
RomfsContainers = [];
|
||||
ExefsContainers = [];
|
||||
RomfsDirs = [];
|
||||
ExefsDirs = [];
|
||||
Cheats = [];
|
||||
}
|
||||
}
|
||||
|
||||
@ -106,9 +106,9 @@ namespace Ryujinx.HLE.HOS
|
||||
|
||||
public PatchCache()
|
||||
{
|
||||
NsoPatches = new List<Mod<DirectoryInfo>>();
|
||||
NroPatches = new List<Mod<DirectoryInfo>>();
|
||||
KipPatches = new List<Mod<DirectoryInfo>>();
|
||||
NsoPatches = [];
|
||||
NroPatches = [];
|
||||
KipPatches = [];
|
||||
|
||||
Initialized = false;
|
||||
}
|
||||
@ -357,7 +357,7 @@ namespace Ryujinx.HLE.HOS
|
||||
private static IEnumerable<Cheat> GetCheatsInFile(FileInfo cheatFile)
|
||||
{
|
||||
string cheatName = DefaultCheatName;
|
||||
List<string> instructions = new();
|
||||
List<string> instructions = [];
|
||||
|
||||
using StreamReader cheatData = cheatFile.OpenText();
|
||||
while (cheatData.ReadLine() is { } line)
|
||||
@ -384,7 +384,7 @@ namespace Ryujinx.HLE.HOS
|
||||
|
||||
// Start a new cheat section.
|
||||
cheatName = line[1..^1];
|
||||
instructions = new List<string>();
|
||||
instructions = [];
|
||||
}
|
||||
else if (line.Length > 0)
|
||||
{
|
||||
@ -470,7 +470,7 @@ namespace Ryujinx.HLE.HOS
|
||||
return baseStorage;
|
||||
}
|
||||
|
||||
HashSet<string> fileSet = new();
|
||||
HashSet<string> fileSet = [];
|
||||
RomFsBuilder builder = new();
|
||||
int count = 0;
|
||||
|
||||
|
Reference in New Issue
Block a user