mirror of
https://git.ryujinx.app/projects/Kenji-NX.git
synced 2026-09-27 12:57:54 +02:00
Use the new C# 14 null propagation setter
This commit is contained in:
@@ -885,10 +885,7 @@ namespace Ryujinx.HLE.HOS.Diagnostics.Demangler
|
||||
result = new NestedName(name, prev);
|
||||
}
|
||||
|
||||
if (context != null)
|
||||
{
|
||||
context.FinishWithTemplateArguments = false;
|
||||
}
|
||||
context?.FinishWithTemplateArguments = false;
|
||||
|
||||
return result;
|
||||
}
|
||||
@@ -1068,10 +1065,7 @@ namespace Ryujinx.HLE.HOS.Diagnostics.Demangler
|
||||
return null;
|
||||
}
|
||||
|
||||
if (context != null)
|
||||
{
|
||||
context.CtorDtorConversion = true;
|
||||
}
|
||||
context?.CtorDtorConversion = true;
|
||||
|
||||
return new ConversionOperatorType(type);
|
||||
default:
|
||||
@@ -1339,10 +1333,7 @@ namespace Ryujinx.HLE.HOS.Diagnostics.Demangler
|
||||
|
||||
_position++;
|
||||
|
||||
if (context != null)
|
||||
{
|
||||
context.CtorDtorConversion = true;
|
||||
}
|
||||
context?.CtorDtorConversion = true;
|
||||
|
||||
if (isInherited && ParseName(context) == null)
|
||||
{
|
||||
@@ -1362,10 +1353,7 @@ namespace Ryujinx.HLE.HOS.Diagnostics.Demangler
|
||||
|
||||
_position++;
|
||||
|
||||
if (context != null)
|
||||
{
|
||||
context.CtorDtorConversion = true;
|
||||
}
|
||||
context?.CtorDtorConversion = true;
|
||||
|
||||
return new CtorDtorNameType(prev, true);
|
||||
}
|
||||
@@ -2968,16 +2956,10 @@ namespace Ryujinx.HLE.HOS.Diagnostics.Demangler
|
||||
|
||||
BaseNode result = null;
|
||||
CvType cv = new(ParseCvQualifiers(), null);
|
||||
if (context != null)
|
||||
{
|
||||
context.Cv = cv;
|
||||
}
|
||||
context?.Cv = cv;
|
||||
|
||||
SimpleReferenceType Ref = ParseRefQualifiers();
|
||||
if (context != null)
|
||||
{
|
||||
context.Ref = Ref;
|
||||
}
|
||||
context?.Ref = Ref;
|
||||
|
||||
if (ConsumeIf("St"))
|
||||
{
|
||||
@@ -3022,10 +3004,7 @@ namespace Ryujinx.HLE.HOS.Diagnostics.Demangler
|
||||
}
|
||||
|
||||
result = new NameTypeWithTemplateArguments(result, templateArgument);
|
||||
if (context != null)
|
||||
{
|
||||
context.FinishWithTemplateArguments = true;
|
||||
}
|
||||
context?.FinishWithTemplateArguments = true;
|
||||
|
||||
_substitutionList.Add(result);
|
||||
continue;
|
||||
@@ -3215,10 +3194,7 @@ namespace Ryujinx.HLE.HOS.Diagnostics.Demangler
|
||||
return null;
|
||||
}
|
||||
|
||||
if (context != null)
|
||||
{
|
||||
context.FinishWithTemplateArguments = true;
|
||||
}
|
||||
context?.FinishWithTemplateArguments = true;
|
||||
|
||||
return new NameTypeWithTemplateArguments(substitution, templateArguments);
|
||||
}
|
||||
@@ -3238,10 +3214,7 @@ namespace Ryujinx.HLE.HOS.Diagnostics.Demangler
|
||||
return null;
|
||||
}
|
||||
|
||||
if (context != null)
|
||||
{
|
||||
context.FinishWithTemplateArguments = true;
|
||||
}
|
||||
context?.FinishWithTemplateArguments = true;
|
||||
|
||||
return new NameTypeWithTemplateArguments(result, templateArguments);
|
||||
}
|
||||
|
||||
@@ -177,10 +177,7 @@ namespace Ryujinx.HLE.HOS.Kernel.Threading
|
||||
|
||||
if (previousThread != nextThread)
|
||||
{
|
||||
if (previousThread != null)
|
||||
{
|
||||
previousThread.LastScheduledTime = PerformanceCounter.ElapsedTicks;
|
||||
}
|
||||
previousThread?.LastScheduledTime = PerformanceCounter.ElapsedTicks;
|
||||
|
||||
_state.SelectedThread = nextThread;
|
||||
_state.NeedsScheduling = true;
|
||||
|
||||
@@ -1169,9 +1169,7 @@ namespace Ryujinx.HLE.HOS.Services.Sockets.Bsd
|
||||
|
||||
public override void DestroyAtExit()
|
||||
{
|
||||
if (_context != null) {
|
||||
_context.Dispose();
|
||||
}
|
||||
_context?.Dispose();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user