How do you use Data.Text.intersperse :: Char -> Text -> Text?

Andrew Lelechenko andrew.lelechenko at gmail.com
Sun Jun 27 19:00:40 UTC 2021


>>> `intersperse :: Char -> Text -> Text`
>> 
>> Yeah, that looks silly indeed.  Should be pruned or marked as spam.
>> 
> 
> "Spam" is a bit harsh.  And it does indeed have some use (albeit primarily
> with test suites and quite possibly more efficient ways to do the required
> task anyway):
> https://github.com/search?l=Haskell&q=Text.intersperse&type=Code

To be honest, I cannot find a single useful application of `intersperse` there, and most of results are not about `Data.Text.intersperse` at all. 

Best regards,
Andrew


More information about the Libraries mailing list