true when fn is a function created by Athena: a global the
environment installed, a newcclosure wrapper, a
loadstring chunk, or otherwise a closure Athena owns. Registered under several
names for compatibility: checkclosure, isourclosure, isexecutorfunction.
Parameters
any
required
The value to test. Non-function values are accepted and simply return
false.Returns
boolean
true if the function belongs to Athena, false otherwise.Behavior
Unlike the other classifiers,isexecutorclosure does not error on a
non-function argument. A non-function just returns false, which matches how
scripts tend to use it as a guard.
A function counts as Athena’s whether it’s a C wrapper, an elevated Luau chunk, or
a cloned or hooked closure that inherited Athena’s origin. Game functions and the
game’s own closures return false.
Example
Related
checkcaller: ask about the running thread instead of a value.isnewcclosure: specifically the wrapper subset.