• simonpj's avatar
    [project @ 2000-07-14 08:17:36 by simonpj] · 77a8c0db
    simonpj authored
    This commit completely re-does the kind-inference mechanism.
    Previously it was inter-wound with type inference, but that was
    always hard to understand, and it finally broke when we started
    checking for ambiguity when type-checking a type signature (details
    irrelevant).
    
    So now kind inference is more clearly separated, so that it never
    takes place at the same time as type inference.  The biggest change
    is in TcTyClsDecls, which does the kind inference for a group of
    type and class declarations.  It now contains comments to explain
    how it all works.
    
    There are also comments in TypeRep which describes the slightly
    tricky way in which we deal with the fact that kind 'type' (written
    '*') actually has 'boxed type' and 'unboxed type' as sub-kinds.
    The whole thing is a bit of a hack, because we don't really have 
    sub-kinding, but it's less of a hack than before.
    
    A lot of general tidying up happened at the same time.
    In particular, I removed some dead code here and there
    77a8c0db
HsDecls.lhs 18.8 KB