mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-21 09:27:59 +02:00
IndexRange protection fix
This commit is contained in:
parent
1fd19c7672
commit
14794e5574
3 changed files with 11 additions and 11 deletions
|
@ -177,7 +177,7 @@ namespace System
|
|||
get
|
||||
{
|
||||
T* start;
|
||||
switch (range.mStart)
|
||||
switch (range.[Friend]mStart)
|
||||
{
|
||||
case .FromFront(let offset):
|
||||
Debug.Assert((uint)offset <= (uint)mLength);
|
||||
|
@ -187,9 +187,9 @@ namespace System
|
|||
start = mPtr + mLength - 1 - offset;
|
||||
}
|
||||
T* end;
|
||||
if (range.mIsClosed)
|
||||
if (range.[Friend]mIsClosed)
|
||||
{
|
||||
switch (range.mEnd)
|
||||
switch (range.[Friend]mEnd)
|
||||
{
|
||||
case .FromFront(let offset):
|
||||
Debug.Assert((uint)offset < (uint)mLength);
|
||||
|
@ -201,7 +201,7 @@ namespace System
|
|||
}
|
||||
else
|
||||
{
|
||||
switch (range.mEnd)
|
||||
switch (range.[Friend]mEnd)
|
||||
{
|
||||
case .FromFront(let offset):
|
||||
Debug.Assert((uint)offset <= (uint)mLength);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue