Map.to_list

You're seeing just the function to_list, go back to Map module for more information.

Specs

to_list(map()) :: [{term(), term()}]

Converts map to a list.

Each key-value pair in the map is converted to a two-element tuple {key, value} in the resulting list.

Inlined by the compiler.

Examples

iex> Map.to_list(%{a: 1})
[a: 1]
iex> Map.to_list(%{1 => 2})
[{1, 2}]