Hacker News new | ask | show | jobs
by querulous 1080 days ago
how does the type system handle `receive` in erlang/elixir? does it just require every `receive` clause have a catchall case (meaning every `receive` is any -> T) or does it only guarantee type checking in the absence of external messages?
1 comments

When you receive, we will use the pattern and guards from the "receive" to lift type information, but we won't verify the messages between processes in our initial efforts. Personally, as future work, I am more interested in typing behaviours, because that's how most users define and interact with processes.