var/list/L = list("A" = 20, "B" = 21, "C" = 22)
//Something like:
var/A = L.A
var/A = L..A
var/A = L@A
//Compiling to:
var/A = L["A"]
//Same for:
L.A = 2
L..A = 2
L@A = 2
//Compiling to:
L["A"] = 2
This would only work for string keys.
L.A is preferred but the other proposed operators are due to things like .len, and the new 512 method chaining, which might complicate things (could perhaps just not allow .len etc, to be converted?)
Associative lists alrady do something similar when defined:
var/list/L = list(A = 20, B = 21, C = 22)
//Already compiles to:
var/list/L = list("A" = 20, "B" = 21, "C" = 22)
So it feels like it would fit in the language
I feel this would just be a nice piece of sugar, I use assoc lists A LOT and being able to do it quicker would be great.
Putting a clear line between list and object is good. Not to mention the hell it would be if Lummox added another property to lists later down the line, and the code begins conflicting.