I'm trying to get to know what modules are in Elixir. Because in Erlang they're just atoms, but in Elixir atoms start with :
character.
So I've checked these expressions in iex:
iex(16)> is_atom(List)
true
iex(17)> is_atom(:List)
true
iex(18)> List == :List
false
iex(19)> a = List
List
iex(20)> b = :List
:List
So it's pretty clear that both List
and :List
are atoms. However, how does it work on Erlang interop layer? Because Erlang's ok
is equal to Elixir's :ok
.
So which one of these two (List
and :List
) is equal to 'List'
in Erlang?