3 ms·
An Elixir macro guru would have to verify, but you could do some funny stuff with a macro that takes a keyword list to get syntax like: function foo: [int:
by dqv 9y ago
An Elixir macro guru would have to verify, but you could do some funny stuff with a macro that takes a keyword list to get syntax like:
function foo: [int: bar] do
bar * bar
end
But, no the Erlang type system is not what you'd normally expect. I really like this paper on success types that kind of goes over the type system: http://user.it.uu.se/~kostis/Papers/succ_types.pdf http://user.it.uu.se/~kostis/Papers/succ_types.pdf