haskell - 为什么 haddock 不为​​ base 中的某些模块生成 HTML?

标签 haskell haddock

base中有一些模块没有文档链接的黑线鳕。例如,GHC/Show.hs有黑线鳕评论,但 Hackage 上没有关于 GHC.Show 模块的文档。为什么不?这是错误吗?

最佳答案

这显然是故意的。它是 this line 的结果在 GHC/Show.hs 中:

{-# OPTIONS_HADDOCK hide #-}

相关摘录自the haddock documentation :

Certain attributes may be specified for each module which affects the way that Haddock generates documentation for that module. Attributes are specified in a comma-separated list in an {-# OPTIONS_HADDOCK ... #-} pragma at the top of the module, either before or after the module description.

[...]

The following attributes are currently understood by Haddock:

  • hide

    Omit this module from the generated documentation, but nevertheless propagate definitions and documentation from within this module to modules that re-export those definitions.

[...]

关于haskell - 为什么 haddock 不为​​ base 中的某些模块生成 HTML?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44415396/

相关文章:

haskell - 为什么 haskell map 不适用于 (-1)?

haskell - cabal : dist/doc/html/creatur/haddock-prolog27972. txt:无效参数

haskell - 黑线鳕超链接并且没有关于冗余导入的警告

list - 丢弃索引中的元素,元素元组

haskell - Haskell中使用NaN的最大值和最小值

haskell - 为什么黑线鳕不生成文档?

haskell - Haddock:用推断的类型签名记录声明?

haskell - 文件开头无用的种类相等错误

haskell - 用parsec解析递归数据