1. 17 Feb, 2014 1 commit
    • Austin Seipp's avatar
      Fix #8770 · dc080915
      Austin Seipp authored
      
      
      As usual, Mac OS X is extremely annoying (or the software is, anyway),
      because not only does it load dynamic libraries with the .dylib
      extension, but also the .so extension. For whatever reason. At least
      it's easy to fix.
      Signed-off-by: default avatarAustin Seipp <austin@well-typed.com>
      dc080915
  2. 09 Jan, 2014 1 commit
    • Simon Peyton Jones's avatar
      Re-work the naming story for the GHCi prompt (Trac #8649) · 73c08ab1
      Simon Peyton Jones authored
      The basic idea here is simple, and described in Note [The interactive package]
      in HscTypes, which starts thus:
      
          Note [The interactive package]
          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          Type and class declarations at the command prompt are treated as if
          they were defined in modules
             interactive:Ghci1
             interactive:Ghci2
             ...etc...
          with each bunch of declarations using a new module, all sharing a
          common package 'interactive' (see Module.interactivePackageId, and
          PrelNames.mkInteractiveModule).
      
          This scheme deals well with shadowing.  For example:
      
             ghci> data T = A
             ghci> data T = B
             ghci> :i A
             data Ghci1.T = A  -- Defined at <interactive>:2:10
      
          Here we must display info about constructor A, but its type T has been
          shadowed by the second declaration.  But it has a respectable
          qualified name (Ghci1.T), and its source location says where it was
          defined.
      
          So the main invariant continues to hold, that in any session an original
          name M.T only refers to oe unique thing.  (In a previous iteration both
          the T's above were called :Interactive.T, albeit with different uniques,
          which gave rise to all sorts of trouble.)
      
      This scheme deals nicely with the original problem.  It allows us to
      eliminate a couple of grotseque hacks
        - Note [Outputable Orig RdrName] in HscTypes
        - Note [interactive name cache] in IfaceEnv
      (both these comments have gone, because the hacks they describe are no
      longer necessary). I was also able to simplify Outputable.QueryQualifyName,
      so that it takes a Module/OccName as args rather than a Name.
      
      However, matters are never simple, and this change took me an
      unreasonably long time to get right.  There are some details in
      Note [The interactive package] in HscTypes.
      73c08ab1
  3. 11 Oct, 2013 1 commit
  4. 22 Sep, 2013 1 commit
  5. 19 Aug, 2013 1 commit
  6. 14 Aug, 2013 1 commit
  7. 23 Jun, 2013 1 commit
  8. 19 Jun, 2013 1 commit
  9. 21 May, 2013 1 commit
  10. 14 May, 2013 1 commit
  11. 16 Mar, 2013 2 commits
  12. 15 Mar, 2013 1 commit
  13. 02 Mar, 2013 1 commit
  14. 30 Jan, 2013 1 commit
  15. 29 Nov, 2012 1 commit
  16. 24 Oct, 2012 1 commit
  17. 19 Oct, 2012 1 commit
  18. 16 Oct, 2012 1 commit
    • ian@well-typed.com's avatar
      Some alpha renaming · cd33eefd
      ian@well-typed.com authored
      Mostly d -> g (matching DynFlag -> GeneralFlag).
      Also renamed if* to when*, matching the Haskell if/when names
      cd33eefd
  19. 13 Oct, 2012 1 commit
  20. 04 Oct, 2012 2 commits
    • ian@well-typed.com's avatar
      Make adjust_ul handle BCOs · 6784dddc
      ian@well-typed.com authored
      We never ran into this before, because replace_osuf was almost always
      False (i.e. we were almost always using the vanilla way when using
      bytecode, so adjust_ul wasn't needed). Now that we can have the dynamic
      way on by default many tests were failing because of it.
      6784dddc
    • ian@well-typed.com's avatar
      Load the right object files in ghci · b49ad6bb
      ian@well-typed.com authored
      When we have a dynamic ghc, we need to load the dynamic object files
      b49ad6bb
  21. 03 Oct, 2012 1 commit
  22. 17 Sep, 2012 1 commit
  23. 16 Sep, 2012 1 commit
  24. 03 Sep, 2012 1 commit
  25. 28 Aug, 2012 2 commits
  26. 02 Jul, 2012 1 commit
  27. 12 Jun, 2012 1 commit
  28. 11 Jun, 2012 1 commit
    • Ian Lynagh's avatar
      Pass DynFlags to the LogAction · 5716a2f8
      Ian Lynagh authored
      A side-effect is that we can no longer use the LogAction in
      defaultErrorHandler, as we don't have DynFlags at that point.
      But all that defaultErrorHandler did is to print Strings as
      SevFatal, so now it takes a 'FatalMessager' instead.
      5716a2f8
  29. 04 Jun, 2012 1 commit
  30. 29 May, 2012 2 commits
  31. 20 Mar, 2012 1 commit
  32. 12 Jan, 2012 1 commit
    • Simon Peyton Jones's avatar
      Implememt -fdefer-type-errors (Trac #5624) · 5508ada4
      Simon Peyton Jones authored
      This patch implements the idea of deferring (most) type errors to
      runtime, instead emitting only a warning at compile time.  The
      basic idea is very simple:
      
       * The on-the-fly unifier in TcUnify never fails; instead if it
         gets stuck it emits a constraint.
      
       * The constraint solver tries to solve the constraints (and is
         entirely unchanged, hooray).
      
       * The remaining, unsolved constraints (if any) are passed to
         TcErrors.reportUnsolved.  With -fdefer-type-errors, instead of
         emitting an error message, TcErrors emits a warning, AND emits
         a binding for the constraint witness, binding it
         to (error "the error message"), via the new form of evidence
         TcEvidence.EvDelayedError.  So, when the program is run,
         when (and only when) that witness is needed, the program will
         crash with the exact same error message that would have been
         given at compile time.
      
      Simple really.  But, needless to say, the exercise forced me
      into some major refactoring.
      
       * TcErrors is almost entirely rewritten
      
       * EvVarX and WantedEvVar have gone away entirely
      
       * ErrUtils is changed a bit:
           * New Severity field in ErrMsg
           * Renamed the type Message to MsgDoc (this change
             touches a lot of files trivially)
      
       * One minor change is that in the constraint solver we try
         NOT to combine insoluble constraints, like Int~Bool, else
         all such type errors get combined together and result in
         only one error message!
      
       * I moved some definitions from TcSMonad to TcRnTypes,
         where they seem to belong more
      5508ada4
  33. 04 Nov, 2011 1 commit
  34. 18 Oct, 2011 1 commit
  35. 21 Sep, 2011 1 commit
    • Simon Marlow's avatar
      Add support for all top-level declarations to GHCi · 3db75724
      Simon Marlow authored
        This is work mostly done by Daniel Winograd-Cort during his
        internship at MSR Cambridge, with some further refactoring by me.
      
      This commit adds support to GHCi for most top-level declarations that
      can be used in Haskell source files.  Class, data, newtype, type,
      instance are all supported, as are Type Family-related declarations.
      
      The current set of declarations are shown by :show bindings.  As with
      variable bindings, entities bound by newer declarations shadow earlier
      ones.
      
      Tests are in testsuite/tests/ghci/scripts/ghci039--ghci054.
      Documentation to follow.
      3db75724
  36. 03 Aug, 2011 1 commit