aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMateusz Kowalczyk <fuuzetsu@fuuzetsu.co.uk>2014-12-18 07:14:23 +0000
committerMateusz Kowalczyk <fuuzetsu@fuuzetsu.co.uk>2014-12-18 07:14:23 +0000
commitd5090d5e9921a61d0a15a95b088210d51f825033 (patch)
tree2b00817d2c8dc6b27e322a78f57ce6445a9feb96
parentbbe19d79f427b784f6423e72fb77fed9c81832b2 (diff)
Print missing docs by default
Adds --no-print-missing-docs
-rw-r--r--CHANGES2
-rw-r--r--haddock-api/src/Haddock/Interface.hs2
-rw-r--r--haddock-api/src/Haddock/Options.hs6
3 files changed, 6 insertions, 4 deletions
diff --git a/CHANGES b/CHANGES
index 2dd563dd..ef0b1be9 100644
--- a/CHANGES
+++ b/CHANGES
@@ -12,6 +12,8 @@ Changes in version 2.16.0
* Fix parsing of infix identifiers such as ``elem``.
+ * Print missing docs by default and add --no-print-missing-docs
+
Changes in version 2.15.0
* Always read in prologue files as UTF8 (#286 and Cabal #1721)
diff --git a/haddock-api/src/Haddock/Interface.hs b/haddock-api/src/Haddock/Interface.hs
index 60a20fe5..1bb04ed3 100644
--- a/haddock-api/src/Haddock/Interface.hs
+++ b/haddock-api/src/Haddock/Interface.hs
@@ -195,7 +195,7 @@ processModule verbosity modsum flags modMap instIfaceMap = do
else n
out verbosity normal coverageMsg
- when (Flag_PrintMissingDocs `elem` flags
+ when (Flag_NoPrintMissingDocs `notElem` flags
&& not (null undocumentedExports && header)) $ do
out verbosity normal " Missing documentation for:"
unless header $ out verbosity normal " Module header"
diff --git a/haddock-api/src/Haddock/Options.hs b/haddock-api/src/Haddock/Options.hs
index b166de46..3fa6397f 100644
--- a/haddock-api/src/Haddock/Options.hs
+++ b/haddock-api/src/Haddock/Options.hs
@@ -82,7 +82,7 @@ data Flag
| Flag_NoTmpCompDir
| Flag_Qualification String
| Flag_PrettyHtml
- | Flag_PrintMissingDocs
+ | Flag_NoPrintMissingDocs
deriving (Eq)
@@ -170,8 +170,8 @@ options backwardsCompat =
"do not re-direct compilation output to a temporary directory",
Option [] ["pretty-html"] (NoArg Flag_PrettyHtml)
"generate html with newlines and indenting (for use with --html)",
- Option [] ["print-missing-docs"] (NoArg Flag_PrintMissingDocs)
- "print information about any undocumented entities"
+ Option [] ["no-print-missing-docs"] (NoArg Flag_NoPrintMissingDocs)
+ "don't print information about any undocumented entities"
]