Would someone explain the following snippet of code
defmodule P do def f, do: "I am P's f" def g, do: f end
iex> P.g "I am P's f"
When I looked into it seems that ‘f’ inside of g/0 get’s treated as a function. However, how does f() become available to g/0. I thought named functions can’t access variables outside their scope unless
unquote is used