-
Notifications
You must be signed in to change notification settings - Fork 1
Description
At this time, we are wielding Cabal's parser. It is a weird thing: taking ByteString as input, but working in String terms. We end up jumping back and forth between these two types. The perfect solution is to work with Text — the type of arrays of characters.
-
The underlying parser —
parsec— treatsByteStringas a stream of characters. This is not ideal.However,
parsecalso supportsTextand this is what we need. It should be easy to rewrite Cabal's parser to work withText. -
The underlying printer —
pretty— hasStringhard wired into it. This is not ideal.Maybe we can generalize it to
IsString, since it is inbasesince forever?
Were these dependencies appropriately generalized, Cabal's parser could be patched to wield Text on the cheap.
I am unwilling to talk to the maintainers of the packages above — my expectation is that they will not be forthcoming. The local maximum is to patch the dependencies myself and depend on forks.