[Haskell-cafe] Haskell future and UTF8 vs UTF-16

M Farkas-Dyck m.farkasdyck at gmail.com
Tue Feb 13 23:31:35 UTC 2018


On 13/02/2018, Zemyla <zemyla at gmail.com> wrote:
> I'd actually been thinking about whether it'd be worth it to include a
> fingertree of character lengths in order to make length O(1) and
> indexing, take, and drop O(log n). However, a Text is currently three
> unpacked values, and putting something that can't be unboxed in there
> may not be such a good idea.

Yeah, whoever needs these operations likely ought to rather use
`Vector Char` or such, or define a wrapper type including the
character length information, lest we penalize all users for it.


More information about the Haskell-Cafe mailing list