[erlang-bugs] Negative integer literals as map keys

Björn-Egil Dahlberg egil@REDACTED
Wed Apr 30 16:09:34 CEST 2014


Yep, the linter is a bit harsh here. It's suppose to deny all non-value 
keys, which technically is what it does here .. but it is a bit harsh.

I'll look at it.

// Björn-Egil

On 2014-04-30 15:32, Alexey Lebedeff wrote:
> Hi,
>
> As soon as I add unary minus anywhere in a map key, it breaks with 
> "illegal map key" message:
>
> Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:8:8] 
> [async-threads:10] [hipe] [kernel-poll:false]
> Eshell V6.0  (abort with ^G)
> 3> #{ -1 => 1}.
> * 1: illegal map key
> 4> #{ {a, -1} => 1 }.
> * 1: illegal map key
>
>
>
> _______________________________________________
> erlang-bugs mailing list
> erlang-bugs@REDACTED
> http://erlang.org/mailman/listinfo/erlang-bugs

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-bugs/attachments/20140430/3e726dc2/attachment.htm>


More information about the erlang-bugs mailing list