iscclosure

Checks whether a function is a C closure.

Syntax

Signature
iscclosure(Function: function) -> boolean

Aliases

This function has no aliases.

Parameters

ParameterTypeDescription
FunctionfunctionFunction to inspect.

Returns

TypeDescription
booleanTrue for a native C closure.

Notes

Passing a value that is not a function raises an argument error.

Example

Luau
print(iscclosure(print))