mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 11:38:21 +02:00
Fixed strideof/alignof error
This commit is contained in:
parent
588d05767e
commit
02c2dfbb5c
1 changed files with 2 additions and 2 deletions
|
@ -398,7 +398,7 @@ namespace System.Collections
|
|||
Free(oldPtr);
|
||||
return;
|
||||
}
|
||||
Internal.MemCpy(mItems + mSize, addSpan.Ptr, addSpan.Length * alignof(T), alignof(T));
|
||||
Internal.MemCpy(mItems + mSize, addSpan.Ptr, addSpan.Length * strideof(T), alignof(T));
|
||||
mSize += (.)addSpan.Length;
|
||||
#if VERSION_LIST
|
||||
mVersion++;
|
||||
|
@ -567,7 +567,7 @@ namespace System.Collections
|
|||
EnsureCapacity(size, true);
|
||||
int addSize = size - mSize;
|
||||
if (addSize > 0)
|
||||
Internal.MemSet(Ptr + mSize, 0, addSize * alignof(T));
|
||||
Internal.MemSet(Ptr + mSize, 0, addSize * strideof(T));
|
||||
mSize = (.)size;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue