haskell-prettyprinter / haskell-prettyprinter/prettyprinter

`surround` is poorly named

Open
#223 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
309
Forks
43
Avg merge
21h 25m
Merged PRs (30d)
1

Description

Surrounding means to put stuff all around.

From that, I'd infer that `surround a [b, c, d]` means either `a b c d a`, or `a b a c a d a`, but definitely not `b a c a d`, where `b` and `d` are not "surrounded by `a`s.

The standard library use words like `intersperse` or `intercalate`, which imply much better the idea of putting things "in between" other things, rather than all around.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.