1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-10 04:22:20 +02:00

overflow fix

This commit is contained in:
Booklordofthedings 2023-11-27 17:19:19 +01:00
parent 8a283fea75
commit 82bfdfe52e

View file

@ -3118,7 +3118,10 @@ namespace System
{
get
{
return .(mPtr + mMatchPos + 1, mStrLen - mMatchPos);
int offset = 0;
if(mMatchPos < mStrLen)
offset = 1;
return .(mPtr + mMatchPos + offset, mStrLen - (mMatchPos+offset));
}
}
@ -3306,6 +3309,17 @@ namespace System
}
}
public StringView Remnant
{
get
{
int offset = 0;
if(mMatchPos < mStrLen)
offset = mMatchLen;
return .(mPtr + mMatchPos + offset, mStrLen - (mMatchPos+offset));
}
}
public bool MoveNext() mut
{
if (mCurCount >= mMaxCount)