umka-lang icon indicating copy to clipboard operation
umka-lang copied to clipboard

Interface-typed keys collision

Open vtereshkov opened this issue 3 years ago • 0 comments

type Any = interface{}

fn main() {
        m := make(map[Any]int)
        m["ABC"] = 42
        m[int32(4407873)] = 17
        printf(repr(m) + '\n')        // Prints { "ABC" : 17 } 
}

vtereshkov avatar Jul 06 '22 22:07 vtereshkov