Skip to main content
Compares two function values by their function identity. Both arguments must be functions. The function returns the boolean result of function identity(L, 1) == function identity(L, 2). It does not compare function bytecode, source, behavior, hashes, upvalues, or newcclosure mappings. comparefunction is an alias for the same function.

Syntax

Aliases

  • comparefunction

Arguments

Returns

Example

Compare two functions by their function identity.