Note [Runtime representation of modules and tycons]
We generate a binding for M.$modName and M.$tcT for every module M and
data type T. Things to think about
- We want them to be economical on space; ideally pure data with no thunks.
- We do this for every module (except this module GHC.Internal.Types), so we can't
depend on anything else (eg string unpacking code)
That's why we have these terribly low-level representations. The TrName
type lets us use the TrNameS constructor when allocating static data;
but we also need TrNameD for the case where we are deserialising a TyCon
or Module (for example when deserialising a TypeRep), in which case we
can't conveniently come up with an Addr#. References 0
This Note does not link to any other.
Referenced by 1
- Grand plan for Typeable GHC.Tc.Instance.Typeable