Revert "Use source generated json serializers in order to improve code trimming (#4094)" (#4576)

This reverts commit 4ce4299ca2.
This commit is contained in:
gdkchan
2023-03-21 20:14:46 -03:00
committed by GitHub
parent 4ce4299ca2
commit ba95ee54ab
73 changed files with 608 additions and 886 deletions

View File

@ -1,5 +1,5 @@
using Ryujinx.Common.Utilities;
using System.IO;
using System.IO;
using System.Text.Json;
namespace Ryujinx.Common.Logging
{
@ -25,8 +25,12 @@ namespace Ryujinx.Common.Logging
public void Log(object sender, LogEventArgs e)
{
var logEventArgsJson = LogEventArgsJson.FromLogEventArgs(e);
JsonHelper.SerializeToStream(_stream, logEventArgsJson, LogEventJsonSerializerContext.Default.LogEventArgsJson);
string text = JsonSerializer.Serialize(e);
using (BinaryWriter writer = new BinaryWriter(_stream))
{
writer.Write(text);
}
}
public void Dispose()