88using System . Text ;
99using RESPite . Internal ;
1010
11- #if NETCOREAPP3_0_OR_GREATER
11+ #if NET
1212using System . Runtime . Intrinsics ;
1313using System . Runtime . Intrinsics . X86 ;
1414#endif
@@ -797,7 +797,7 @@ internal readonly ReadOnlySpan<byte> Buffer(Span<byte> target)
797797 return simple ;
798798 }
799799
800- #if NET6_0_OR_GREATER
800+ #if NET
801801 return BufferSlow ( ref Unsafe . NullRef < byte [ ] > ( ) , target , usePool : false ) ;
802802#else
803803 byte [ ] pooled = [ ] ;
@@ -1019,7 +1019,7 @@ private void MovePastCurrent()
10191019
10201020 /// <inheritdoc cref="RespReader"/>
10211021 public RespReader ( scoped in ReadOnlySequence< byte > value)
1022- #if NETCOREAPP3_0_OR_GREATER
1022+ #if NET
10231023 : this ( value . FirstSpan )
10241024#else
10251025 : this ( value . First . Span )
@@ -1046,7 +1046,7 @@ public unsafe bool TryReadNext()
10461046 {
10471047 MovePastCurrent ( ) ;
10481048
1049- #if NETCOREAPP3_0_OR_GREATER
1049+ #if NET
10501050 // check what we have available; don't worry about zero/fetching the next segment; this is only
10511051 // for SIMD lookup, and zero would only apply when data ends exactly on segment boundaries, which
10521052 // is incredible niche
@@ -1883,7 +1883,7 @@ public readonly bool ReadBoolean()
18831883 /// <typeparam name="T">The type of enum being parsed.</typeparam>
18841884 public readonly T ReadEnum < T > ( T unknownValue = default ) where T : struct , Enum
18851885 {
1886- #if NET6_0_OR_GREATER
1886+ #if NET
18871887 return ParseChars ( static ( chars , state ) => Enum . TryParse ( chars , true , out T value ) ? value : state , unknownValue ) ;
18881888#else
18891889 return Enum . TryParse ( ReadString ( ) , true , out T value ) ? value : unknownValue ;
0 commit comments