[commit: ghc] ghc-8.0: users-guide: Add -Wredundant-constraints to flags reference (abca151)

git at git.haskell.org git at git.haskell.org
Thu Mar 24 22:24:06 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : ghc-8.0
Link       : http://ghc.haskell.org/trac/ghc/changeset/abca1519926aa1a2c62d929a95a723037ebfe517/ghc

>---------------------------------------------------------------

commit abca1519926aa1a2c62d929a95a723037ebfe517
Author: Ben Gamari <bgamari.foss at gmail.com>
Date:   Thu Mar 24 22:32:20 2016 +0100

    users-guide: Add -Wredundant-constraints to flags reference
    
    Test Plan: Validate and read
    
    Reviewers: austin
    
    Subscribers: thomie
    
    Differential Revision: https://phabricator.haskell.org/D2035
    
    GHC Trac Issues: #11741
    
    (cherry picked from commit 8ff6518b5af1b357eb043ac46f9209bd0019a193)


>---------------------------------------------------------------

abca1519926aa1a2c62d929a95a723037ebfe517
 docs/users_guide/using-warnings.rst       | 2 ++
 utils/mkUserGuidePart/Options/Warnings.hs | 7 +++++++
 2 files changed, 9 insertions(+)

diff --git a/docs/users_guide/using-warnings.rst b/docs/users_guide/using-warnings.rst
index ffe5a41..16c6585 100644
--- a/docs/users_guide/using-warnings.rst
+++ b/docs/users_guide/using-warnings.rst
@@ -398,6 +398,8 @@ of ``-W(no-)*``.
 
 .. ghc-flag:: -Wredundant-constraints
 
+    :since: 8.0
+
     .. index::
        single: redundant constraints, warning
 
diff --git a/utils/mkUserGuidePart/Options/Warnings.hs b/utils/mkUserGuidePart/Options/Warnings.hs
index b194bf2..3552172 100644
--- a/utils/mkUserGuidePart/Options/Warnings.hs
+++ b/utils/mkUserGuidePart/Options/Warnings.hs
@@ -370,6 +370,13 @@ warningsOptions =
          , flagType = DynamicFlag
          , flagReverse = "-Wno-amp"
          }
+  , flag { flagName = "-Wredundant-constraints"
+         , flagDescription =
+           "Have the compiler warn about redundant constraints in type"++
+           "signatures."
+         , flagType = DynamicFlag
+         , flagReverse = "-Wno-redundant-constraints"
+         }
   , flag { flagName = "-Wdeferred-type-errors"
          , flagDescription =
            "Report warnings when :ref:`deferred type errors "++



More information about the ghc-commits mailing list