1. 01 Dec, 2015 1 commit
  2. 29 Nov, 2015 11 commits
  3. 28 Nov, 2015 1 commit
  4. 27 Nov, 2015 2 commits
  5. 26 Nov, 2015 3 commits
  6. 25 Nov, 2015 8 commits
  7. 24 Nov, 2015 9 commits
    • Ben Gamari's avatar
      DynFlags: Drop stale comment · 76f3142d
      Ben Gamari authored
      76f3142d
    • Simon Peyton Jones's avatar
      Simplify the MonadFail code · 5e04c384
      Simon Peyton Jones authored
      Simplify and tidy up the MonadFail code.
      See TcMatches.tcMonadFailOp
      
      Less, code; and more robust.
      
      This incidentally fixes a bug; see the change
      to MonadFailErrors.stderr
      5e04c384
    • Simon Peyton Jones's avatar
      Comments only · 8dc6da83
      Simon Peyton Jones authored
      8dc6da83
    • Ben Gamari's avatar
      8c5fe53b
    • Ben Gamari's avatar
      Rewrite checkUniques and incorporate into validate · e506f02d
      Ben Gamari authored
      This should catch duplicate uniques in the future before Bad Things
      happen.
      
      Test Plan: Introduce a duplicate unique and validate
      
      Reviewers: austin, hvr, thomie
      
      Reviewed By: hvr, thomie
      
      Subscribers: thomie
      
      Differential Revision: https://phabricator.haskell.org/D1521
      e506f02d
    • quchen's avatar
      Add -Wcompat warning flag group · 6d147939
      quchen authored
      Reviewers: hvr, austin, thomie, bgamari
      
      Reviewed By: hvr, austin, thomie, bgamari
      
      Subscribers: thomie
      
      Differential Revision: https://phabricator.haskell.org/D1495
      
      GHC Trac Issues: #11000
      6d147939
    • elaforge's avatar
      Rearrange error msgs and add section markers (Trac #11014). · c05fddde
      elaforge authored
      This puts the "Relevant bindings" section at the end.
      
      It uses a TcErrors.Report Monoid to divide messages by importance and
      then mappends them together.  This is not the most efficient way since
      there are various intermediate Reports and list appends, but it probably
      doesn't matter since error messages shouldn't get that large, and are
      usually prepended.  In practice, everything is `important` except
      `relevantBindings`, which is `supplementary`.
      
      ErrMsg's errMsgShortDoc and errMsgExtraInfo were extracted into ErrDoc,
      which has important, context, and suppelementary fields.  Each of those
      three sections is marked with a bullet character, '•' on unicode
      terminals and '*' on ascii terminals.  Since this breaks tons of tests,
      I also modified testlib.normalise_errmsg to strip out '•'s.
      
      --- Additional notes:
      
      To avoid prepending * to an empty doc, I needed to filter empty docs.
      This seemed less error-prone than trying to modify everyone who produces
      SDoc to instead produce Maybe SDoc.  So I added `Outputable.isEmpty`.
      Unfortunately it needs a DynFlags, which is kind of bogus, but otherwise
      I think I'd need another Empty case for SDoc, and then it couldn't be a
      newtype any more.
      
      ErrMsg's errMsgShortString is only used by the Show instance, which is
      in turn only used by Show HscTypes.SourceError, which is in turn only
      needed for the Exception instance.  So it's probably possible to get rid
      of errMsgShortString, but that would a be an unrelated cleanup.
      
      Fixes #11014.
      
      Test Plan: see above
      
      Reviewers: austin, simonpj, thomie, bgamari
      
      Reviewed By: thomie, bgamari
      
      Subscribers: simonpj, nomeata, thomie
      
      Differential Revision: https://phabricator.haskell.org/D1427
      
      GHC Trac Issues: #11014
      c05fddde
    • Herbert Valerio Riedel's avatar
      Implement new `-fwarn-noncanonical-monad-instances` · f09f2470
      Herbert Valerio Riedel authored
      Warn about incoherent/non-canonical 'Applicative'/'Monad' instance
      declarations. Specifically the following invariants are checked:
      
      In 'Monad' instances declarations warn if the any of the following
      conditions does not hold:
      
       * If `return` is overridden it must be canonical (i.e. `return = pure`).
       * If `(>>)` is overridden it must be canonical (i.e. `(>>) = (*>)`).
      
      In 'Applicative' instance declarations:
      
       * Warn if 'pure' is defined backwards (i.e. `pure = return`).
       * Warn if '(*>)' is defined backwards (i.e. `(*>) = (>>)`).
      
      NB, this warning flag is not enabled via `-Wall` nor `-Wcompat`.
      
      This addresses #11128
      
      Reviewers: quchen, austin, bgamari
      
      Reviewed By: bgamari
      
      Differential Revision: https://phabricator.haskell.org/D1516
      f09f2470
    • Herbert Valerio Riedel's avatar
      Add `PrelNames.thenAName` for `Applicative(*>)` · 12dbc892
      Herbert Valerio Riedel authored
      This is needed to allow subsequent patches to refer to `*>`.
      
      While at it, this commit also groups together the `Applicative` definitions
      to reduce confusion.
      
      Reviewed By: austin
      
      Differential Revision: https://phabricator.haskell.org/D1513
      12dbc892
  8. 23 Nov, 2015 5 commits