Skip to content
  • Ryan Scott's avatar
    Suppress redundant givens during error reporting · 89ad5fed
    Ryan Scott authored
    Summary:
    When GHC reports that it cannot solve a constraint in error
    messages, it often reports what given constraints it has in scope.
    Unfortunately, sometimes redundant constraints (like `* ~ *`,
    from  #15361) can sneak in. The fix is simple: blast away these
    redundant constraints using `mkMinimalBySCs`.
    
    Test Plan: make test TEST=T15361
    
    Reviewers: simonpj, bgamari
    
    Subscribers: rwbarton, thomie, carter
    
    GHC Trac Issues: #15361
    
    Differential Revision: https://phabricator.haskell.org/D5002
    
    (cherry picked from commit c552feea)
    89ad5fed