[commit: haddock] T6018-injective-type-families, adamse-D1033, ghc-head, master, wip/10268, wip/10313, wip/D538-3, wip/D538-4, wip/D538-5, wip/D538-6, wip/D548-master, wip/D548-master-2, wip/T10483, wip/T9840, wip/api-annot-tweaks-7.10, wip/api-annots-ghc-7.10-3, wip/orf-reboot: Print missing docs by default (d5090d5)

git at git.haskell.org git at git.haskell.org
Wed Jul 8 08:36:02 UTC 2015


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

On branches: T6018-injective-type-families,adamse-D1033,ghc-head,master,wip/10268,wip/10313,wip/D538-3,wip/D538-4,wip/D538-5,wip/D538-6,wip/D548-master,wip/D548-master-2,wip/T10483,wip/T9840,wip/api-annot-tweaks-7.10,wip/api-annots-ghc-7.10-3,wip/orf-reboot
Link       : http://git.haskell.org/haddock.git/commitdiff/d5090d5e9921a61d0a15a95b088210d51f825033

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

commit d5090d5e9921a61d0a15a95b088210d51f825033
Author: Mateusz Kowalczyk <fuuzetsu at fuuzetsu.co.uk>
Date:   Thu Dec 18 07:14:23 2014 +0000

    Print missing docs by default
    
    Adds --no-print-missing-docs


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

d5090d5e9921a61d0a15a95b088210d51f825033
 CHANGES                              | 2 ++
 haddock-api/src/Haddock/Interface.hs | 2 +-
 haddock-api/src/Haddock/Options.hs   | 6 +++---
 3 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/CHANGES b/CHANGES
index 2dd563d..ef0b1be 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 60a20fe..1bb04ed 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 b166de4..3fa6397 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"
   ]
 
 



More information about the ghc-commits mailing list