[GHC] #10365: Implement Semigroup as a superclass of Monoid Proposal (Phase 1)
GHC
ghc-devs at haskell.org
Mon Nov 2 04:05:59 UTC 2015
#10365: Implement Semigroup as a superclass of Monoid Proposal (Phase 1)
-------------------------------------+-------------------------------------
Reporter: gidyn | Owner: quchen
Type: feature request | Status: patch
Priority: high | Milestone: 8.0.1
Component: libraries/base | Version: 7.10.1
Resolution: | Keywords: report-impact
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s): Phab:D1284
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by ekmett):
@nomeata:
FWIW- the implementation in `semigroups` was crafted by mixing and
matching parts between the 2-3 implementations of non-empty lists at the
time. The skeleton of it was build mostly by raiding the `NonEmptyList`
package for parts with permission of the owners. AFAIK, Tony has
deprecated his `NonEmptyList` package in favor of the one in `semigroups`
(hence the lack of updates in the last 5 years -- this changeover predated
having any deprecation mechanism on hackage.)
Robin Kay's `NonEmpty` package is just a data type with no instances and
no methods, also 6 years old.
Cardinality also hasn't seen a patch in 6 years. Remarkably it still
builds, because it too simply provides no instances.
`MinLen` requires a ton of type system extensions.
Out of the things that are suitable to consider as a `base`-ready encoding
of a non-empty list, only Henning's `Data.NonEmpty` is actively
maintained, and it tackles a more general problem, and brings with it a
dozen different ad hoc classes for inserts and the like.
So if you're hunting for materials to use to rebuild the bikeshed
completely, I'd say out of the packages on hackage today, that is the only
real source of lumber.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10365#comment:37>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list