When end) it is interpreted as the end of the function, and incorrectly formats the module.
Example from: https://howistart.org/posts/elixir/1
Lines -> Auto Indent (editor:auto-indent)
defmodule Portal.Door do
...
-- def pop(door) do
---- Agent.get_and_update(door, fn
---- [] -> {:error, []}
---- [h|t] -> {{:ok, h}, t}
---- end)
end
end
The auto-indent interprets end) as end for def pop.
Expected the auto-indent interprets end) as end for Agent.get_and_update:
defmodule Portal.Door do
...
--def pop(door) do
---- Agent.get_and_update(door, fn
---- [] -> {:error, []}
---- [h|t] -> {{:ok, h}, t}
---- end)
--end
end