3 ms·
Yeah, no. That's not what generics mean. A map of any single type with any type for the key is different from a map using generic types. For generics what you
by cratermoon 5y ago
Yeah, no. That's not what generics mean. A map of any single type with any type for the key is different from a map using generic types.
For generics what you want is not interface{}, which says nothing, but a type T that has meaningful constraints.