fix: Fixes span reader ReadString (#1539)
This commit is contained in:
parent
0018901a79
commit
1ebaf5390d
4 changed files with 12 additions and 4 deletions
|
|
@ -277,6 +277,7 @@ public static class StringHelpers
|
|||
_ => buffer.IndexOf((byte)0)
|
||||
};
|
||||
|
||||
// TODO: If returns -1, do not multiply by the byte length
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
public static int IndexOfTerminator(this ReadOnlySpan<byte> buffer, int sizeT) =>
|
||||
sizeT switch
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue