3 ms·
Well, I didn't have much luck last time I responded to you, but I'll try again since you haven't gotten a response yet! Regardless of whether or not it's activ
by sodapopcan 3y ago
Well, I didn't have much luck last time I responded to you, but I'll try again since you haven't gotten a response yet!
Regardless of whether or not it's actively discouraged, it still must be supported since Elixir is so heavily bootstrapped. Since `defmodule`, `def`, etc are all just macros written in Elixir, there are no special rules around which functions/macros are allowed to be called without parens. There was some discussion about that on the forums a while ago (like requiring parens for functions and not for macros) and the answer is that that will never happen.
- throwawaymaths 3y agoWell I mean it wouldn't have been a big deal, if the do block binds to the outermost, then in most cases just would get a compiler error since usually a private fn/0 doesn't exist. Still though in the early days elixir more strongly preferred no-parens, so avoiding that is understandable.
- sodapopcan 3y agoTrue!