Add intercalate to Data.List
Add a function equal to concat (intersperse x xs)
The initial mail for this proposal and the following discussion can be found here: http://www.haskell.org/pipermail/libraries/2006-October/005917.html
A summary of the discussion:
Accepting the patch
A lot of people agreed that including a function such as intercalate in the libraries would be a good thing. Indeed, many said they already had such a function in their own libraries. Jon Fairbairn argued against giving a name to such a short idiom and this was supported by Ketil Malde.
The submitter interpreted this as a clear majority in favour of this patch.
The name 'intercalate'
The original proposal for the name was join. Since it clashes with Control.Monad.join it was deemed inappropriate. Many other names were suggested: separateWith, sepBy, joinWith, concatIntersperse, consperse, intercat, connect, concatInter and intercalate. The original submitter decided for 'intercalate'. A number people said they agreed with this. One person said he preferred joinWith but others argued against that. Some people expressed their concerns against such an uncommon word being used and suggested that there should be some explanation for it. It was agreed that there should be an explanation somewhere on the Wiki.
Split
Bulat Ziganshin suggested also adding a function split which is a right inverse of intercalate. Donald Steward seemed to agree with this decision. No one else raised their voice about this so it seems uncontroversial.
Trac metadata
Trac field | Value |
---|---|
Version | 6.6 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | Unknown |
Architecture | Unknown |