aboutsummaryrefslogtreecommitdiff
path: root/haddock-api
Commit message (Collapse)AuthorAgeFilesLines
* tyThingToLHsDecl: Preserve type synonyms that contain a forall (#880)Simon Jakobi2018-07-191-2/+46
| | | | | | | | | | * tyThingToLHsDecls: Preserve type synonyms that contain a forall Fixes #879. * Add Note [Invariant: Never expand type synonyms] * Clarify Note [Invariant: Never expand type synonyms]
* Avoid line breaks due to line length in Hoogle (#868)Alec Theriault2018-07-061-3/+5
| | | | | | | | | | | | | * Avoid line breaks due to line length in Hoogle Hoogle operates in a line-oriented fashion, so we should avoid ever breaking due to long lines. One way of doing this non-intrusively is to modify the 'DynFlags' that are threaded through the 'Hoogle' module (note this is anyways only passed through for use in the various 'showSDoc' functions). * Amend test case
* Export more fixities for Hoogle (#871)Alec Theriault2018-07-051-2/+2
| | | | This exports fixities for more things, including class methods and type-level operators.
* Renamer: Warn about ambiguous identifiers (#831)Simon Jakobi2018-06-082-5/+19
| | | | | | | | | | | | | | | | | | | * Renamer: Warn about ambiguous identifiers Example: Warning: 'elem' is ambiguous. It is defined * in ‘Data.Foldable’ * at /home/simon/tmp/hdk/src/Lib.hs:7:1 You may be able to disambiguate the identifier by qualifying it or by hiding some imports. Defaulting to 'elem' defined at /home/simon/tmp/hdk/src/Lib.hs:7:1 Fixes #830. * Deduplicate warnings Fixes #832.
* Improve hyperlinker's 'spanToNewline' (#846)Alec Theriault2018-06-051-7/+25
| | | | | | | | | | | | | | | | 'spanToNewline' is used to help break apart the source into lines which can then be partioned into CPP and non-CPP chunks. It is important that 'spanToNewline' not break apart tokens, so it needs to properly handle things like * block comments, possibly nested * string literals, possibly multi-line * CPP macros, possibly multi-line String literals in particular were not being properly handled. The fix is to to fall back in 'Text.Read.lex' to help lex things that are not comments. Fixes #837.
* Bump a few dependency bounds (#845)Simon Jakobi2018-06-051-3/+3
|
* Use `ClassOpSig` instead of `TypeSig` for class methods (#835)Alec Theriault2018-05-231-4/+4
| | | | | | | | * Fix minimal pragma handling Class declarations contain 'ClassOpSig' not 'Typesig'. This should fix #834. * Accept html-test output
* WibblesRyan Scott2018-05-101-3/+3
|
* Remove Hoogle backend hack that butchers infix datatype namesRyan Scott2018-05-101-2/+1
|
* Renamer: Warn about out of scope identifiers. (#819)Simon Jakobi2018-05-081-6/+11
|
* Remove 'TokenGroup' from Hyperlinker (#818)Alec Theriault2018-05-081-50/+14
| | | | | Since the hyperlinker backend now relies on the GHC tokenizer, something like 'Bar.Baz.foo' already gets bunched together into one token (as opposed to being spread across 'Bar', '.', 'Baz', '.', and 'foo').
* Filter out CRLFs in hyperlinker backend (#813)Alec Theriault2018-05-071-2/+7
| | | This prevents spurious lines from appearing in the final output.
* Improve the Hoogle backend's treatment of type families (#808)Ryan Scott2018-04-241-6/+20
| | | Fixes parts 1 and 2 of #806.
* Don't treat fixity signatures like declarationsalexbiehl2018-04-201-1/+1
|
* Travis: Build with ghc-8.4.2 (#793)Alexander Biehl2018-04-031-1/+1
|
* Clear search string on hide for #781 (#789)Jack Henahan2018-04-033-4/+4
|
* Bump haddock and haddock-api to 2.20.0alexbiehl2018-03-281-1/+1
|
* haddock-2.19.1, haddock-api-2.19.1, haddock-library-1.6.0alexbiehl2018-03-271-2/+2
|
* @since includes package name (#749)Alec Theriault2018-03-2712-252/+319
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Metadoc stores a package name This means that '@since' annotations can be package aware. * Get the package name the right way This should extract the package name for `@since` annotations the right way. I had to move `modulePackageInfo` around to do this and, in the process, I took the liberty to update it. Since it appears that finding the package name is something that can fail, I added a warning for this case. * Silence warnings * Hide package for local 'since' annotations As discussed, this is still the usual case (and we should avoid being noisy for it). Although this commit is large, it is basically only about threading a 'Maybe Package' from 'Haddock.render' all the way to 'Haddock.Backends.Xhtml.DocMarkup.renderMeta'. * Bump binary interface version * Add a '--since-qual' option This controls when to qualify since annotations with the package they come from. The default is always, but I've left an 'external' variant where only those annotations coming from outside of the current package are qualified. * Make ParserSpec work * Make Fixtures work * Use package name even if package version is not available The @since stuff needs only the package name passed in, so it makes sense to not be forced to pass in a version too.
* Useful cost centres, timers and allocation counters (#785)Alexander Biehl2018-03-232-27/+53
| | | | | | | | | * Add some useful cost-centres for profiling * Add withTiming for each haddock phase Invoking haddock with `--optghc=-ddump-timings` now shows the amount of time spent and the number of allocated bytes for each phase.
* Show where instances are defined (#748)Alec Theriault2018-03-216-23/+35
| | | | | | | | | | | | | | * Indicate source module of instances Above instance, we now also display a link to the module where the instance was defined. This is sometimes helpful in figuring out what to import. * Source module for type/data families too * Remove parens * Accept tests
* extractDecl: Extract constructor patterns from data family instances (#776)Alexander Biehl2018-03-131-13/+26
| | | | | | * extractDecl: Allow extraction of data family instance constructors * extractDecl: extract data family instance constructors
* Bump lower bound for haddock-libraryalexbiehl2018-03-101-1/+1
|
* Update to QC 2.11Herbert Valerio Riedel2018-03-101-1/+1
|
* Bump haddock-2.19.0.1, haddock-api-2.19.0.1, haddock-library-1.5.0.1alexbiehl2018-03-101-3/+3
|
* Hyperlinker: Links for TyOps, class methods and associated typesalexbiehl2018-03-051-1/+14
|
* Fix file handle leak (#763) (#764)Alec Theriault2018-02-251-3/+6
| | | | Brought back some mistakenly deleted code for handling encoding and eager reading of files from e0ada1743cb722d2f82498a95b201f3ffb303137.
* Hoogle/Latex: Remove use of partial functionAlexander Biehl2018-02-192-7/+5
|
* Teach the HTML backend how to render methods with multiple namesalexbiehl2018-02-192-31/+7
|
* Add 'show' option to complement 'hide' (#752)Alec Theriault2018-02-112-10/+17
| | | | | | | | | | | | * Add 'show' option to complement 'hide' The behaviour is for flags passed in the command line to override flags in file headers. In the command line, later flags override earlier ones. Fixes #751 and #266. * Add a '--show-all' option
* Add module tooltips to linked identifiers (#753)Alec Theriault2018-02-111-3/+5
| | | No more clicking to figure out whether your bytestring is strict or lazy!
* Expand SigD in a better placealexbiehl2018-02-091-2/+2
| | | | | | | | In https://github.com/haskell/haddock/issues/287 we found that haddock-2.19.0 would miss documentation on class methods with multiples names. This patch uses expandSigDecls in a more sensible place.
* Hyperlinker: Also link pattern synonym argumentsalexbiehl2018-02-061-2/+5
|
* fullModuleContents: support named docsalexbiehl2018-02-061-16/+24
|
* Expand SigDsalexbiehl2018-02-061-2/+26
|
* Rename: renameHsSpliceTy ttgalexbiehl2018-02-061-1/+1
|
* Don't barf on 'HsSpliceTy' (#745)Alec Theriault2018-02-061-1/+12
| | | | | | | | This handles 'HsSpliceTy's by replacing them with what they expand to. IIUC everything that is happening, 'renameHsSpliceTy' should not be able to fail for the inputs we feed it from GHC. This fixes #574.
* Don't warn about missing '~' (#746)Alec Theriault2018-02-061-5/+14
| | | | | | | This manually filters out '~' from the list of things to warn about. It truly makes no sense to warn on this since '~' has nothing it could link to - it is magical. This fixes #532.
* Hyperlink pattern synonyms and 'module' imports (#744)Alec Theriault2018-02-051-4/+10
| | | | | | Links to pattern synonyms are now generated, as well as links from modules in import lists. Fixes #731.
* Add `SPDX-License-Identifier` as alised for "license" module header tokensHerbert Valerio Riedel2018-02-051-5/+6
| | | | | | | | | | | C.f. SPDX 2.1 - Appendix V https://spdx.org/spdx-specification-21-web-version#h.twlc0ztnng3b The tag should appear on its own line in the source file, generally as part of a comment. SPDX-License-Identifier: <SPDX License Expression> Cherry-picked from #743
* Use withBinaryFilealexbiehl2018-02-041-1/+1
|
* QuickJump: Mitigate encoding problems on Windowsalexbiehl2018-02-031-4/+5
|
* Support the new 'ITcolumn_prag' tokenAlec Theriault2018-02-021-0/+2
|
* Properly color pragma contents in hyperlinkerAlec Theriault2018-02-021-13/+65
| | | | | | The hyperlinker backend now classifies the content of pragmas as 'TkPragma'. That means that in something like '{-# INLINE foo #-}', 'foo' still gets classified as a pragma token.
* hadock-2.19.0 / haddock-api-2.19.0 / haddock-library-1.5.0Alexander Biehl2018-02-011-3/+3
|
* Warning free compilationAlexander Biehl2018-02-014-4/+1
|
* Convert: Correct pass typeAlexander Biehl2018-02-011-2/+1
|
* Specialize: Add missing IdP annotationsAlexander Biehl2018-02-011-2/+2
|
* Hyperlinker: Adjust parser to new PFailed constructorAlexander Biehl2018-02-011-8/+8
|
* Quickjump Scrollable overlayAlexander Biehl2018-02-011-2/+2
|