I see in some places a function along with its arity is prefixed by & like &function/3
. Can I know what this means or how this works? I understand the usage of &
in anonymous functions but this case is not clear to me.
And I also see in some cases an anonymous function is suffixed by a parentheses like this (fn x -> {:ok, x} end).()
. What does this mean?