Two anonymous functions are equal if they were created from the same definition (same fn ... statement) in the same module (same checksum), and have the exact same environment variables.
Funs defined in the shell satisfy the first two as long as their arity is the same, but differ in the latter as they’re interpreted by the shell which drags in a ton of stuff to their environment. If you want consistent results please try this with compiled modules instead.


















