elixir
elixir copied to clipboard
Set-theoretic tuple types
Adds to the Descr tuple types {:ok, binary(), integer()} and open tuple types {atom(), boolean(), ...} which represent every tuple of at least two elements that are an atom and a boolean.
Tuples are encoded as map records, where the keys are the indices. E.g., type {integer(), atom()} is encoded as type %{0 => integer(), 1 => atom()} and {atom(), boolean(), ...} is encoded as the open map %{..., 0 => atom(), 1 => boolean()}.
Emptiness checking is slightly modified to account for the fact that tuple types do not admit explicit optional indices.