newlclosure
Wraps a function in a Luau closure.
Syntax
Signature
newlclosure(Function: function) -> functionAliases
This function has no aliases.
Parameters
| Parameter | Type | Description |
|---|---|---|
Function | function | Function called by the forwarding closure. |
Returns
| Type | Description |
|---|---|
function | New Luau closure. |
Notes
Function may be a Luau or C closure.
Example
Luau
local Result = newlclosure(function() return 42 end)
print(Result)