4 ms·
You can do success type-checking w/ dialyzer, so there's already a way to think about this. An instance of a gen_server is a pid, the become message in this exa
by wcummings 10y ago
You can do success type-checking w/ dialyzer, so there's already a way to think about this. An instance of a gen_server is a pid, the become message in this example is a tuple of an atom and function.
http://erlang.org/doc/reference_manual/typespec.html http://erlang.org/doc/reference_manual/typespec.html
- platz 10y agoof course, but I wouldn't assume success typing (dialyzer) is compatible with static parametric typing, ala purescript
- im_down_w_otp 10y agoI'm not sure I'm seeing the gap. You get parametric types with Dialyzer + type specs. There are also several flags you can enable for Dialyzer to make its checking more strict and exhaustive. Now that the escape hatch from type safety, that was impossible to avoid using Maps, has been mostly closed (and you're under no obligation to use Maps to begin with) it's not at all clear to me what you wouldn't be able to do.