diff options
author | Manav Rathi <mx4492@gmail.com> | 2016-02-25 14:51:32 +0100 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2016-02-25 15:41:55 +0100 |
commit | 665849142bca36c14bcb25d64180c153a1ef1f2c (patch) | |
tree | 64d4787d0e2af14ed57d637aaced6cc54a167571 /docs/users_guide/using-warnings.rst | |
parent | 673efccb3b348e9daf23d9e65460691bbea8586e (diff) | |
download | haskell-665849142bca36c14bcb25d64180c153a1ef1f2c.tar.gz |
Make warning names more consistent
- Replace "Sigs" with "Signatures" in WarningFlag data constructors.
- Replace "PatSyn" with "PatternSynonym" in WarningFlag data
constructors.
- Deprecate "missing-local-sigs" in favor of "missing-local-signatures".
- Deprecate "missing-exported-sigs" in favor of
"missing-exported-signatures".
- Deprecate "missing-pat-syn-signatures" in favor of
"missing-pattern-synonym-signatures".
- Replace "ddump-strsigs" with "ddump-str-signatures"
These complete the tasks that were explicitly mentioned in #11583
Test Plan:
Executed `ghc --show-options` and verified that the flags were changed
as expected.
Reviewers: svenpanne, austin, bgamari
Reviewed By: austin, bgamari
Subscribers: mpickering, thomie
Differential Revision: https://phabricator.haskell.org/D1939
GHC Trac Issues: #11583
Diffstat (limited to 'docs/users_guide/using-warnings.rst')
-rw-r--r-- | docs/users_guide/using-warnings.rst | 49 |
1 files changed, 34 insertions, 15 deletions
diff --git a/docs/users_guide/using-warnings.rst b/docs/users_guide/using-warnings.rst index e71ae927ef..24f8039451 100644 --- a/docs/users_guide/using-warnings.rst +++ b/docs/users_guide/using-warnings.rst @@ -62,8 +62,8 @@ The following flags are simple ways to select standard "packages" of warnings: * :ghc-flag:`-Wincomplete-record-updates` * :ghc-flag:`-Wmonomorphism-restriction` * :ghc-flag:`-Wimplicit-prelude` - * :ghc-flag:`-Wmissing-local-sigs` - * :ghc-flag:`-Wmissing-exported-sigs` + * :ghc-flag:`-Wmissing-local-signatures` + * :ghc-flag:`-Wmissing-exported-signatures` * :ghc-flag:`-Wmissing-import-lists` * :ghc-flag:`-Widentities` @@ -598,32 +598,51 @@ of ``-W(no-)*``. .. index:: single: type signatures, missing + This option is now deprecated in favour of + :ghc-flag:`-Wmissing-exported-signatures`. + +.. ghc-flag:: -Wmissing-exported-signatures + + .. index:: + single: type signatures, missing + If you would like GHC to check that every exported top-level function/value has a type signature, but not check unexported - values, use the :ghc-flag:`-Wmissing-exported-sigs` option. This option - takes precedence over :ghc-flag:`-Wmissing-signatures`. As part of the - warning GHC also reports the inferred type. The option is off by - default. + values, use the :ghc-flag:`-Wmissing-exported-signatures` + option. This option takes precedence over + :ghc-flag:`-Wmissing-signatures`. As part of the warning GHC also + reports the inferred type. The option is off by default. .. ghc-flag:: -Wmissing-local-sigs .. index:: single: type signatures, missing - If you use the :ghc-flag:`-Wmissing-local-sigs` flag GHC will warn you - about any polymorphic local bindings. As part of the warning GHC - also reports the inferred type. The option is off by default. + This option is now deprecated in favour of + :ghc-flag:`-Wmissing-local-signatures`. + +.. ghc-flag:: -Wmissing-local-signatures + + .. index:: + single: type signatures, missing + + If you use the :ghc-flag:`-Wmissing-local-signatures` flag GHC + will warn you about any polymorphic local bindings. As part of the + warning GHC also reports the inferred type. The option is off by + default. -.. ghc-flag:: -Wmissing-pat-syn-signatures +.. ghc-flag:: -Wmissing-pattern-synonym-signatures .. index:: single: type signatures, missing, pattern synonyms - If you would like GHC to check that every pattern synonym has a type - signature, use the :ghc-flag:`-Wmissing-pat-syn-signatures` option. If this option is - used in conjunction with :ghc-flag:`-Wmissing-exported-sigs` then only - exported pattern synonyms must have a type signature. GHC also reports the - inferred type. This option is off by default. + If you would like GHC to check that every pattern synonym has a + type signature, use the + :ghc-flag:`-Wmissing-pattern-synonym-signatures` option. If this + option is used in conjunction with + :ghc-flag:`-Wmissing-exported-signatures` then only exported pattern + synonyms must have a type signature. GHC also reports the inferred + type. This option is off by default. .. ghc-flag:: -Wname-shadowing |