mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-17 15:46:05 +02:00
StringView comparison
This commit is contained in:
parent
637765d840
commit
518583ef00
1 changed files with 5 additions and 0 deletions
|
@ -2841,6 +2841,11 @@ namespace System
|
||||||
return String.[Friend]EqualsHelper(ptr1, ptr2, val1.mLength);
|
return String.[Friend]EqualsHelper(ptr1, ptr2, val1.mLength);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static int operator<=>(StringView val1, StringView val2)
|
||||||
|
{
|
||||||
|
return String.[Friend]CompareOrdinalHelper(val1.mPtr, val1.mLength, val2.mPtr, val2.mLength);
|
||||||
|
}
|
||||||
|
|
||||||
public static int Compare(StringView val1, StringView val2, bool ignoreCase = false)
|
public static int Compare(StringView val1, StringView val2, bool ignoreCase = false)
|
||||||
{
|
{
|
||||||
if (ignoreCase)
|
if (ignoreCase)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue