Why shorthand limitation for maps?

Hey there! I’m new to Elixir.

The docs says about using maps:
When the key in a key-value pair is an atom, the key: value shorthand syntax can be used (as in many other special forms), provided key-value pairs are put at the end

I’m curious, what’s the reason for putting them at the end?
Thanks! :smiley:

1 Like

Its easier to implement in the parser. It will just “create” a KW list at the end, only the %{} special form then will know that the KW list at the end has this special meaning.

1 Like