`data class <T> MyClass(...)` should work
# getting-started
m
data class <T> MyClass(...)
should work
m
I think you mean MyClass<T>, but wouldn't that mean that T would be the same class for every key/value pair in the map?
m
yes, that is true
m
In that map, I need to have <Key<Int>, Int> and <Key<String>, String> pairs
m
try using upper bounds
m
not sure what those are
you can bound
T
to multiple types
where T : Int, T : String
but tbh, not sure it would work in your scenario
m
I know, I looked there, but I think that would allow <Key<Int>, String> pairs
m
good point, I missed that one
m
I'll keep looking 🙂
m
cool, thanks for getting back with some answer