gnu: Add kafs-client
[jackhill/guix/guix.git] / gnu / packages / patches / ghc-haddock-api-fix-haddock.patch
1 This patch is taken from upstream. It fixes documentation generation.
2 The patch has been lightly adapted to apply to the release tarball, but
3 the commit message was left untouched, so it refers to some changes not
4 included in the patch.
5
6 From 0d9a81e20238a6b72f9f5c005f1f7e9cf05f6fb9 Mon Sep 17 00:00:00 2001
7 From: Alec Theriault <alec.theriault@gmail.com>
8 Date: Sat, 27 Oct 2018 10:05:04 -0700
9 Subject: [PATCH] Fix documentation in `haddock-api` (#957)
10
11 * Fix misplaced Haddocks in Haddock itself
12
13 Haddock should be able to generate documentation for 'haddock-api'
14 again.
15
16 * Make CI check that documentation can be built.
17
18 * Add back a doc that is OK
19 ---
20 .travis.yml | 3 +++
21 haddock-api/src/Haddock/Backends/LaTeX.hs | 10 +++++-----
22 2 files changed, 8 insertions(+), 5 deletions(-)
23
24 diff --git a/src/Haddock/Backends/LaTeX.hs b/src/Haddock/Backends/LaTeX.hs
25 index 4e0e6eba..613c6deb 100644
26 --- a/src/Haddock/Backends/LaTeX.hs
27 +++ b/src/Haddock/Backends/LaTeX.hs
28 @@ -243,8 +243,8 @@ ppDocGroup lev doc = sec lev <> braces doc
29
30 -- | Given a declaration, extract out the names being declared
31 declNames :: LHsDecl DocNameI
32 - -> ( LaTeX -- ^ to print before each name in an export list
33 - , [DocName] -- ^ names being declared
34 + -> ( LaTeX -- to print before each name in an export list
35 + , [DocName] -- names being declared
36 )
37 declNames (L _ decl) = case decl of
38 TyClD _ d -> (empty, [tcdName d])
39 @@ -444,9 +444,9 @@ ppLPatSig doc docnames ty unicode
40 -- arguments as needed.
41 ppTypeOrFunSig :: HsType DocNameI
42 -> DocForDecl DocName -- ^ documentation
43 - -> ( LaTeX -- ^ first-line (no-argument docs only)
44 - , LaTeX -- ^ first-line (argument docs only)
45 - , LaTeX -- ^ type prefix (argument docs only)
46 + -> ( LaTeX -- first-line (no-argument docs only)
47 + , LaTeX -- first-line (argument docs only)
48 + , LaTeX -- type prefix (argument docs only)
49 )
50 -> Bool -- ^ unicode
51 -> LaTeX
52 --
53 2.23.0
54