4 ms·
>> I accidentally pass in 3 params instead of 4 to a function (with static typing this does not compile) > In Erlang this will also not compile, unless you hav
by filmor 6y ago
>> I accidentally pass in 3 params instead of 4 to a function (with static typing this does not compile)
> In Erlang this will also not compile, unless you have a 3 parameter version of the function, in which case static typing will not help you.
This is only true if the function you are calling is part of the same module (and is not called in module:func(Args)-form). If it's not, Erlang will happily compile it and you'll have to rely on xref to catch the error.
This is one of the compromises it takes to get hot code reload.