lune/tests/ffi/pretty_print/arr.luau
2024-11-09 12:46:20 +00:00

6 lines
229 B
Text

local ffi = require("@lune/ffi")
local c = ffi.c
assert(typeof(c.int:arr(5)) :: string == "CArrInfo")
assert(tostring(c.int:arr(5)) == " int, length = 5 ")
assert(tostring(c.int:ptr():arr(5)) == " <CPtrInfo(int)>, length = 5 ")