한국어 👈
Polyfill libraries for dalbit used transpiling luau to lua (especially Lua 5.3)
-
typeof
-
unpack
-
newproxy
-
gcinfo
- More details here
-
buffer
-
math
-
os
(sandboxed) -
string
-
table
-
debug
-
bit32
-
utf8
- Benchmarks
next
polyfill functions (betweenluauNext
anddjb2Next
)
- Please do not depend on error messages. since we can't compare table and number(primitive types), polyfill's custom types such as
userdata
type will be shown astable
when comparing numbers like this example code.
local a = newproxy() < 2 -- errors: "attempt to compare table < number"
-- correct error message: "attempt to compare userdata < number"
- Please do not depend on hash table's orders. while the polyfill is trying to use/imitate
Luau
's hash table implementations, it might still have some critical edge cases with orders(especially with number hashing and pointer hashing. the order is not guaranteed asLuau
's one) Lua 5.3
has integers so there may be slightly different behavior.- There may still be differences from
Luau
due to differences inLua
version and environment.
- Luau - Some implementations of the polyfill were inspired/ported from original
Luau
's source code(especially hash tables) - Dekkonot - For bitbuffer and hashing function that calculates
a * b
mod 32 for polyfill's luauNext implementation. - Contributors of kaledis - For bugs/issues finding/solving(especially
bit32
implementations forLua 5.1
) and battle testing in their cool project.