Skip to content
This repository was archived by the owner on Aug 3, 2024. It is now read-only.

Small fixes #1045

Merged
merged 4 commits into from
Mar 9, 2019
Merged

Small fixes #1045

merged 4 commits into from
Mar 9, 2019

Conversation

harpocrates
Copy link
Collaborator

A mishmash of changes (all individually compiling + passing tests) that I've accumulated over the past release cycle.

Some of these from from the Hi Haddock branch. Moving them out of that patch (especially since they don't really have anything to do with Hi Haddock) seems like a good idea.

  * default methods now get rendered differently
  * default associated types get rendered
  * fix a forgotten `s/TypeSig/ClassOpSig/` refactor in LaTeX backend
  * LaTeX backend now renders default method signatures

NB: there is still no way to document default class members and the
NB: LaTeX backend still crashes on associated types
`markupWarning` often processes inputs which span across paragraphs.
Unfortunately, LaTeX's `emph` is not made to handle this (and will
crash).

Fixes haskell#936.
After this commit, we can run with `--latex` on all boot libraries
without crashing (although the generated LaTeX still fails to compile in
a handful of larger packages like `ghc` and `base`).

 * Add newlines after all block elements in LaTeX. This is important to
   prevent the final output from being more an more indented. See the
   `latext-test/src/Example` test case for a sample of this.

 * Support associated types in class declarations (but not yet defaults)

 * Several small issues for producing compiling LaTeX;
     - avoid empy `\haddockbeginargs` lists (ex: `type family Any`)
     - properly escape identifiers depending on context (ex: `Int#`)
     - add `vbox` around `itemize`/`enumerate` (so they can be in tables)

 * Several spacing fixes:
     - limit the width of `Pretty`-arranged monospaced code
     - cut out extra space characters in export lists
     - only escape spaces if there are _multiple_ spaces
     - allow type signatures to be multiline (even without docs)

 * Remove uninteresting and repetitive `main.tex`/`haddock.sty` files
   from `latex-test` test reference output.

Fixes haskell#935, haskell#929 (LaTeX docs for `text` build & compile)
Fixes haskell#727, haskell#930 (I think both are really about type families...)
@harpocrates harpocrates merged commit ae23b4f into haskell:ghc-8.8 Mar 9, 2019
@harpocrates harpocrates deleted the small-fixes branch March 9, 2019 19:22
@harpocrates harpocrates mentioned this pull request Sep 13, 2019
4 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant