diff --git a/src/Utf8StringInterpolation/Shims.cs b/src/Utf8StringInterpolation/Shims.cs index 4f38727..d20b9f1 100644 --- a/src/Utf8StringInterpolation/Shims.cs +++ b/src/Utf8StringInterpolation/Shims.cs @@ -1,8 +1,5 @@ #pragma warning disable CA2014 // Do not use stackalloc in loops - -#pragma warning disable CA2014 // Do not use stackalloc in loops - using System.Buffers.Text; using System.Text; diff --git a/src/Utf8StringInterpolation/Utf8StringInterpolation.csproj b/src/Utf8StringInterpolation/Utf8StringInterpolation.csproj index 00b2afc..21734ab 100644 --- a/src/Utf8StringInterpolation/Utf8StringInterpolation.csproj +++ b/src/Utf8StringInterpolation/Utf8StringInterpolation.csproj @@ -5,16 +5,12 @@ enable 11 enable - + true $(NoWarn);CS1591;CA2255 string Successor of ZString; UTF8 based zero allocation high-peformance String Interpolation and StringBuilder. - - true - - diff --git a/src/Utf8StringInterpolation/Utf8StringWriter.cs b/src/Utf8StringInterpolation/Utf8StringWriter.cs index 2d98ef5..d3d8396 100644 --- a/src/Utf8StringInterpolation/Utf8StringWriter.cs +++ b/src/Utf8StringInterpolation/Utf8StringWriter.cs @@ -214,7 +214,7 @@ public void AppendFormatted(string value, int alignment = 0, string? format = nu #if NETSTANDARD2_0 unsafe { - fixed (byte* ptr = &destination[currentWritten]) + fixed (byte* ptr = &destination[0]) { charCount = Encoding.UTF8.GetCharCount(ptr, bytesWritten); }