Skip to content

cabal new-haddock produces no documentation for single module executables #5890

@int-e

Description

@int-e

With the following .cabal file (and any Main.hs),

name: nodoc
version: 0
build-type: Simple
cabal-version: >= 1.2

executable nodoc
  main-is: Main.hs
  other-modules:
  build-depends: base

no documentation is produced by cabal new-haddock --haddock-executables. As soon as one adds at least one module to the other-modules specification, documentation is generated, including the Main module.

$ cabal --version
cabal-install version 2.4.1.0
compiled using version 2.4.1.0 of the Cabal library
$ haddock --version
Haddock version 2.20.0, (c) Simon Marlow 2006
Ported to use the GHC API by David Waern 2006-2008
$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 8.4.2

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions