mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
feat: Lua-style array append support in Bytearray
This commit is contained in:
parent
303e861fbb
commit
d8feff56c0
2 changed files with 27 additions and 15 deletions
8
dev/tests/bytearray.lua
Normal file
8
dev/tests/bytearray.lua
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
local arr = Bytearray()
|
||||
assert(#arr == 0)
|
||||
|
||||
for i=1,10 do
|
||||
arr[i] = 10 - i
|
||||
assert(#arr == i)
|
||||
assert(arr[i] == 10 - i)
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue