Enable MA0044 and fix noncompliance

"Remove useless ToString call" (on a `string`)
This commit is contained in:
YoshiRulz 2024-07-04 06:36:57 +10:00
parent 9f0009b972
commit 1f7d75b7d2
No known key found for this signature in database
GPG Key ID: C4DE31C245353FB7
2 changed files with 1 additions and 2 deletions

View File

@ -187,7 +187,7 @@ dotnet_diagnostic.MA0042.severity = error
# Use nameof operator in ArgumentException
dotnet_diagnostic.MA0043.severity = error
# Remove useless ToString call
dotnet_diagnostic.MA0044.severity = silent
dotnet_diagnostic.MA0044.severity = warning
# Do not use blocking call in a sync method (need to make containing method async)
dotnet_diagnostic.MA0045.severity = silent
# Use EventHandler<T> to declare events

View File

@ -98,7 +98,6 @@ namespace BizHawk.Emulation.Cores.Components.ARM
if (Str(d, s, false))
return null;
string[] ret = Encoding.ASCII.GetString(s.total, 0, Array.IndexOf(s.total, (byte)0))
.ToString()
.Split(new string[] {" "}, 2, StringSplitOptions.None);
return ret[0].PadRight(8) + (ret.Length > 1 ? ret[1] : "");
}