mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-11-08 01:28:34 +00:00
"Exists" method should be used instead of the "Any" extension (#5345)
This commit is contained in:
parent
d604e98227
commit
7608cb37ab
|
@ -512,7 +512,7 @@ namespace Ryujinx.Graphics.Gpu.Image
|
|||
/// <returns>True if at least one of the handles is dirty</returns>
|
||||
private bool CheckDirty()
|
||||
{
|
||||
return Handles.Any(handle => handle.Dirty);
|
||||
return Array.Exists(Handles, handle => handle.Dirty);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
|
@ -256,7 +256,7 @@ namespace Ryujinx.Graphics.Vulkan
|
|||
{
|
||||
await Task.WhenAll(_shaders.Select(shader => shader.CompileTask));
|
||||
|
||||
if (_shaders.Any(shader => shader.CompileStatus == ProgramLinkStatus.Failure))
|
||||
if (Array.Exists(_shaders, shader => shader.CompileStatus == ProgramLinkStatus.Failure))
|
||||
{
|
||||
LinkStatus = ProgramLinkStatus.Failure;
|
||||
|
||||
|
|
|
@ -206,7 +206,7 @@ namespace Ryujinx.HLE.HOS.Kernel.Threading
|
|||
|
||||
WakeThreads(_condVarThreads, count, TryAcquireMutex, x => x.CondVarAddress == address);
|
||||
|
||||
if (!_condVarThreads.Any(x => x.CondVarAddress == address))
|
||||
if (!_condVarThreads.Exists(x => x.CondVarAddress == address))
|
||||
{
|
||||
KernelTransfer.KernelToUser(address, 0);
|
||||
}
|
||||
|
|
|
@ -95,7 +95,7 @@ namespace Ryujinx.HLE.HOS.Services.Nfc.Nfp
|
|||
{
|
||||
VirtualAmiiboFile virtualAmiiboFile = LoadAmiiboFile(amiiboId);
|
||||
|
||||
if (virtualAmiiboFile.ApplicationAreas.Any(item => item.ApplicationAreaId == applicationAreaId))
|
||||
if (virtualAmiiboFile.ApplicationAreas.Exists(item => item.ApplicationAreaId == applicationAreaId))
|
||||
{
|
||||
_openedApplicationAreaId = applicationAreaId;
|
||||
|
||||
|
@ -124,7 +124,7 @@ namespace Ryujinx.HLE.HOS.Services.Nfc.Nfp
|
|||
{
|
||||
VirtualAmiiboFile virtualAmiiboFile = LoadAmiiboFile(amiiboId);
|
||||
|
||||
if (virtualAmiiboFile.ApplicationAreas.Any(item => item.ApplicationAreaId == applicationAreaId))
|
||||
if (virtualAmiiboFile.ApplicationAreas.Exists(item => item.ApplicationAreaId == applicationAreaId))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
@ -144,7 +144,7 @@ namespace Ryujinx.HLE.HOS.Services.Nfc.Nfp
|
|||
{
|
||||
VirtualAmiiboFile virtualAmiiboFile = LoadAmiiboFile(amiiboId);
|
||||
|
||||
if (virtualAmiiboFile.ApplicationAreas.Any(item => item.ApplicationAreaId == _openedApplicationAreaId))
|
||||
if (virtualAmiiboFile.ApplicationAreas.Exists(item => item.ApplicationAreaId == _openedApplicationAreaId))
|
||||
{
|
||||
for (int i = 0; i < virtualAmiiboFile.ApplicationAreas.Count; i++)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue