should the Indexed classes have their fundep?
Closed this issue · 3 comments
matthewleon commented
All the indexed classes have a f -> i fundep. Isn't it conceivable, though, that a given f could have instances for different i types? With the fundep, you'd have to use Newtype to get this behavior.
LiamGoodacre commented
Do you have a specific example scenario?
matthewleon commented
An ordered StringMap could be indexed by both Strings and Integers.
hdgarrood commented
Having the fundep should help inference and will improve error messages, so I'm tempted to say that I'd rather keep it. This example, for me, isn't compelling enough to give up what the fundep gives us.