~ruther/NosSmooth

dcb624dd6cf4e0b0bb6b95d3d6b73c6c80e1f67f — František Boháček 3 years ago c076813
chore: remove debug stuff from source generator
1 files changed, 1 insertions(+), 6 deletions(-)

M Packets/NosSmooth.PacketSerializersGenerator/SourceGenerator.cs
M Packets/NosSmooth.PacketSerializersGenerator/SourceGenerator.cs => Packets/NosSmooth.PacketSerializersGenerator/SourceGenerator.cs +1 -6
@@ 64,7 64,7 @@ public class SourceGenerator : ISourceGenerator
    /// <inheritdoc />
    public void Initialize(GeneratorInitializationContext context)
    {
        SpinWait.SpinUntil(() => Debugger.IsAttached);
        // SpinWait.SpinUntil(() => Debugger.IsAttached);
    }

    private IEnumerable<RecordDeclarationSyntax> GetPacketRecords(Compilation compilation, SyntaxTree tree)


@@ 130,11 130,6 @@ public class SourceGenerator : ISourceGenerator
                    $"{packetRecord.GetPrefix()}.{packetRecord.Identifier.NormalizeWhitespace().ToFullString()}Converter.g.cs",
                    stringWriter.GetStringBuilder().ToString()
                );
                File.WriteAllText
                (
                    $"/tmp/{packetRecord.GetPrefix()}.{packetRecord.Identifier.NormalizeWhitespace().ToFullString()}Converter.g.cs",
                    stringWriter.GetStringBuilder().ToString()
                );
            }
        }


Do not follow this link