Kernel.SpecialForms.__aliases__
You're seeing just the macro
__aliases__
, go back to Kernel.SpecialForms module for more information.
Internal special form to hold aliases information.
It is usually compiled to an atom:
iex> quote do
...> Foo.Bar
...> end
{:__aliases__, [alias: false], [:Foo, :Bar]}
Elixir represents Foo.Bar
as __aliases__
so calls can be
unambiguously identified by the operator :.
. For example:
iex> quote do
...> Foo.bar()
...> end
{{:., [], [{:__aliases__, [alias: false], [:Foo]}, :bar]}, [], []}
Whenever an expression iterator sees a :.
as the tuple key,
it can be sure that it represents a call and the second argument
in the list is an atom.
On the other hand, aliases hold some properties:
The head element of aliases can be any term that must expand to an atom at compilation time.
The tail elements of aliases are guaranteed to always be atoms.
When the head element of aliases is the atom
:Elixir
, no expansion happens.