mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 04:22:20 +02:00
overflow fix
This commit is contained in:
parent
8a283fea75
commit
82bfdfe52e
1 changed files with 15 additions and 1 deletions
|
@ -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)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue