diff options
| -rw-r--r-- | docs/users_guide/using-warnings.rst | 13 | ||||
| -rw-r--r-- | utils/mkUserGuidePart/Options/Warnings.hs | 7 |
2 files changed, 20 insertions, 0 deletions
diff --git a/docs/users_guide/using-warnings.rst b/docs/users_guide/using-warnings.rst index 9bc1c35590..9f10efb866 100644 --- a/docs/users_guide/using-warnings.rst +++ b/docs/users_guide/using-warnings.rst @@ -17,6 +17,7 @@ generally likely to indicate bugs in your program. These are: * :ghc-flag:`-Woverlapping-patterns` * :ghc-flag:`-Wwarnings-deprecations` + * :ghc-flag:`-Wdeprecations` * :ghc-flag:`-Wdeprecated-flags` * :ghc-flag:`-Wunrecognised-pragmas` * :ghc-flag:`-Wduplicate-constraints` @@ -246,6 +247,18 @@ of ``-W(no-)*``. This option is on by default. +.. ghc-flag:: -Wdeprecations + + .. index:: + single: deprecations + + Causes a warning to be emitted when a module, function or type with + a ``WARNING`` or ``DEPRECATED pragma`` is used. See + :ref:`warning-deprecated-pragma` for more details on the pragmas. + An alias for :ghc-flag:`-Wwarnings-deprecations`. + + This option is on by default. + .. ghc-flag:: -Wamp .. index:: diff --git a/utils/mkUserGuidePart/Options/Warnings.hs b/utils/mkUserGuidePart/Options/Warnings.hs index 48ee32ce6c..620c7312e7 100644 --- a/utils/mkUserGuidePart/Options/Warnings.hs +++ b/utils/mkUserGuidePart/Options/Warnings.hs @@ -401,6 +401,13 @@ warningsOptions = , flagType = DynamicFlag , flagReverse = "-Wno-warnings-deprecations" } + , flag { flagName = "-Wdeprecations" + , flagDescription = + "warn about uses of functions & types that have warnings or "++ + "deprecated pragmas. Alias for :ghc-flag:`-Wwarnings-deprecations`" + , flagType = DynamicFlag + , flagReverse = "-Wno-deprecations" + } , flag { flagName = "-Wamp" , flagDescription = "*(deprecated)* warn on definitions conflicting with the "++ |
