[erlang-questions] printed maps look confusing

Loïc Hoguin essen@REDACTED
Mon Feb 3 14:58:49 CET 2014


Removing the spaces doesn't work at all. Example:

#{<<"hello">>=><<"bye">>}

Adding a space after the comma is OK but when pretty printing over lines 
of 80 characters it's going to make things a lot worse.

The current solution sounds best to me. Just gotta get used to it.

On 02/03/2014 02:44 PM, Vlad Dumitrescu wrote:
> Hi!
>
> The default format for printing maps puts no space after the comma, but
> only around the =>. The result looks confusing to me.
>
> #{2 => 3,4 => 5}
>
> 3 and 4 look more related than 2 and 3 or 4 and 5.
>
> Fixing this is a bit more job than adding a space, unless one wants to
> add them to lists and tuples too. Removing the spaces around the arrow
> doesn't look too nice either.
>
> I can write a patch, but what is the best solution?
>
> regards,
> Vlad
>
>
>
>
>
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
>

-- 
Loïc Hoguin
http://ninenines.eu



More information about the erlang-questions mailing list