true when fn is a Luau closure: a function backed by compiled Luau
bytecode. This is the exact inverse of iscclosure.
Parameters
function
required
The function to classify.
Returns
boolean
true for a Luau closure, false for a C closure.Behavior
Only Luau closures carry a proto, so atrue result here is the precondition for
the bytecode-based functions: getfunctionhash,
debug.getconstants, debug.getproto, and so on.
Example
Errors
Related
iscclosure: the inverse test.getfunctionhash: requires a Luau closure.