1. 20 Apr, 2012 1 commit
    • Simon Peyton Jones's avatar
      Do SCC on instance declarations (fixes Trac #5715) · fa9fdc28
      Simon Peyton Jones authored
      The trouble here is that given
      
          {-# LANGUAGE DataKinds, TypeFamilies #-}
          data instance Foo a = Bar (Bar a)
      
      we want to get a sensible message that we can't use the promoted 'Bar'
      constructor until after its definition; it's a staging error.  Bud the
      staging mechanism that we use for vanilla data declarations don't work
      here.
      
      Solution is to perform strongly-connected component analysis on the
      instance declarations. But that in turn means that we need to track
      free-variable information on more HsSyn declarations, which is why
      so many files are touched.  All the changes are boiler-platey except
      the ones in TcInstDcls.
      fa9fdc28
  2. 16 Apr, 2012 2 commits
  3. 13 Apr, 2012 5 commits
    • Simon Peyton Jones's avatar
    • Simon Peyton Jones's avatar
      Allow kind-variable binders in type signatures · c5554f82
      Simon Peyton Jones authored
      This is the last major addition to the kind-polymorphism story,
      by allowing (Trac #5938)
      
       type family F a   -- F :: forall k. k -> *
       data T a          -- T :: forall k. k -> *
       type instance F (T (a :: Maybe k)) = Char
      
      The new thing is the explicit 'k' in the type signature on 'a',
      which itself is inside a type pattern for F.
      
      Main changes are:
      
      * HsTypes.HsBSig now has a *pair* (kvs, tvs) of binders,
        the kind variables and the type variables
      
      * extractHsTyRdrTyVars returns a pair (kvs, tvs)
        and the function itself has moved from RdrHsSyn to RnTypes
      
      * Quite a bit of fiddling with
           TcHsType.tcHsPatSigType and tcPatSig
        which have become a bit simpler.  I'm still not satisfied
        though.  There's some consequential fiddling in TcRules too.
      
      * Removed the unused HsUtils.collectSigTysFromPats
      
      There's a consequential wibble to Haddock too
      c5554f82
    • Simon Peyton Jones's avatar
      Untabify HsTypes · 3377abeb
      Simon Peyton Jones authored
      3377abeb
    • Simon Peyton Jones's avatar
      Revert "Added ':runmonad' command to GHCi" · e0e99f99
      Simon Peyton Jones authored
      Two problems, for now at any rate
        a) Breaks the build with lots of errors like
              No instance for (Show (IO ())) arising from a use of `print'
        b) Discussion of the approache hasn't converged yet
           (Simon M had a number of suggestions)
      
      This reverts commit eecd7c98.
      e0e99f99
    • dterei's avatar
      Added ':runmonad' command to GHCi · eecd7c98
      dterei authored
      This command allows you to lift user stmts in GHCi into an IO monad
      that implements the GHC.GHCi.GHCiSandboxIO type class. This allows for
      easy sandboxing of GHCi using :runmonad and Safe Haskell.
      
      Longer term it would be nice to allow a more general model for the Monad
      than GHCiSandboxIO but delaying this for the moment.
      eecd7c98
  4. 12 Apr, 2012 6 commits
  5. 11 Apr, 2012 10 commits
  6. 10 Apr, 2012 4 commits
  7. 09 Apr, 2012 1 commit
  8. 06 Apr, 2012 1 commit
  9. 05 Apr, 2012 10 commits