mail at joachim-breitner.de
Fri Feb 22 19:52:00 CET 2013
another status report about my base-splitting experiment:
The list of packages has grown to
* base-pure: Basic stuff without `IO`, `Foreign` or floating point
* base-st: The `ST` monad, uses base-pure.
* base-array: Arrays, uses base-st.
* base-float: Floating point types, uses base-array internally.
* base-io: The `IO` monad, uses base-st.
* base-concurrent: Currently just `MVar`, uses base-io.
* base-foreign: Everything related to `Foreign`, uses base-io and
base-float (for the `Storable` instances for `Double` and `Float`).
Of the (exactly!) 200 modules in base, 83 have not yet been sorted into
these or other packages:
Inspired by a similar graph by Herbert Valerio Riedel, I tried to
visualize the current state and came up with this:
It is not completely accurate due to Prelude not included in
-ddump-minimal-imports (but that shouldn’t matter as most interesting
functions of the Prelude are in base-pure). The script to
generate the dot file from *.imports is included in the branch at
Next I’d need to see how entangled the system-close stuff is (File IO,
Of course with too much splitting one runs in the Bane of the Orphaned
Instances – neither should base-foreign require base-float nor the other
way around, but "Storable Double" needs to be define somewhere... And
the same question will arise if Data.Date should go to a package of its
Also, I notice that there is an issue with “internal” modules (mostly
GHC.something) that should not be part of some stable API, but needed to
implement packages further down. Should they just not be considered part
of the “public” (and PVP-relevant) API? Or should there be two packages,
e.g. base-pure-internal and base-pure, where the latter re-exports those
modules that are meant for public consumption?
So, what is the general opinion? Is this a way worth pursuing? Or are we
fine with the huge base and I can do different things again ;-)?
Joachim "nomeata" Breitner
nomeata at debian.org | ICQ# 74513189 | GPG-Keyid: 4743206C
JID: nomeata at joachim-breitner.de | http://people.debian.org/~nomeata
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 198 bytes
Desc: This is a digitally signed message part
More information about the Glasgow-haskell-users