Eq, Ord and Hashable classes and instances for the key part of a data type