Hello,
I am using Go 1.20.4 on Ubuntu 22.04. I am facing a compilation error when I attempt to pass a map from a string to a struct to a function that expects a map from string to an interface.
Here, the struct is Helper, and it conforms to both interface definitions - Helper1 and Helper2. I am able to pass in an instance of Helper directly, however when I attempt to pass a map[string]Helper the compiler throws a type error IncompatibleAssign.
I was wondering if anyone else has faced something similar? And if so, how did you solve this issue. Would appreciate any input, thank you.
Regards,
Pranay Agarwal