[1.1.101] load() returns nil after updating from 1.1.100 to 1.1.101
Posted: Thu Dec 28, 2023 11:21 am
After updating from 1.1.100 to 1.1.101 the behavior of load() seems to have changed / broken.
The mods i maintain use string.dump() and load() to copy functions, this worked until 1.1.100.
After updating to 1.1.101 load() just returns nil if fed with a string.dump( "Any function" ).
Example:
Create a random function:
Call string.dump() and load() to copy the function:
Expected behavior:
As in 1.1.100, "cloned" contains a copy of "test"
Behavior in 1.1.101:
"cloned" is nil
A mod to reproduce this is attached.
The mods i maintain use string.dump() and load() to copy functions, this worked until 1.1.100.
After updating to 1.1.101 load() just returns nil if fed with a string.dump( "Any function" ).
Example:
Create a random function:
Code: Select all
local test = function() return print("Hello world!") end
Code: Select all
local dumped = string.dump(test)
local cloned = load(dumped)
As in 1.1.100, "cloned" contains a copy of "test"
Behavior in 1.1.101:
"cloned" is nil
A mod to reproduce this is attached.