
30 Apr
2018
30 Apr
'18
5:42 p.m.
Dan Burton wrote:
If you’re going to import Data.Semigroup as a sort of backwards compatibility shim, then I don’t think you should import it qualified. To avoid the ambiguity error, how about “import Data.Monoid hiding ((<>))”?
Likely mempty could be used elsewhere in the module and so Data.Monoid would be needed (when supporting older versions of base). mappend = (Sem.<>) seems like the simplest change to the examples on the wiki page that would avoid the problem. -- see shy jo