diff options
Diffstat (limited to 'src/Ryujinx.Horizon/Sdk/Sf/Cmif/HandlesToClose.cs')
| -rw-r--r-- | src/Ryujinx.Horizon/Sdk/Sf/Cmif/HandlesToClose.cs | 39 |
1 files changed, 28 insertions, 11 deletions
diff --git a/src/Ryujinx.Horizon/Sdk/Sf/Cmif/HandlesToClose.cs b/src/Ryujinx.Horizon/Sdk/Sf/Cmif/HandlesToClose.cs index 0f3b259a..3c37e8b2 100644 --- a/src/Ryujinx.Horizon/Sdk/Sf/Cmif/HandlesToClose.cs +++ b/src/Ryujinx.Horizon/Sdk/Sf/Cmif/HandlesToClose.cs @@ -17,7 +17,7 @@ namespace Ryujinx.Horizon.Sdk.Sf.Cmif public int this[int index] { - get + readonly get { return index switch { @@ -29,22 +29,39 @@ namespace Ryujinx.Horizon.Sdk.Sf.Cmif 5 => _handle5, 6 => _handle6, 7 => _handle7, - _ => throw new IndexOutOfRangeException() + _ => throw new IndexOutOfRangeException(), }; } set { switch (index) { - case 0: _handle0 = value; break; - case 1: _handle1 = value; break; - case 2: _handle2 = value; break; - case 3: _handle3 = value; break; - case 4: _handle4 = value; break; - case 5: _handle5 = value; break; - case 6: _handle6 = value; break; - case 7: _handle7 = value; break; - default: throw new IndexOutOfRangeException(); + case 0: + _handle0 = value; + break; + case 1: + _handle1 = value; + break; + case 2: + _handle2 = value; + break; + case 3: + _handle3 = value; + break; + case 4: + _handle4 = value; + break; + case 5: + _handle5 = value; + break; + case 6: + _handle6 = value; + break; + case 7: + _handle7 = value; + break; + default: + throw new IndexOutOfRangeException(); } } } |
