| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
The problem manifests itself in instances that are defined in
modules other than the module where the class is defined. The fix
is just to thread through the 'Module' of the instance further
along.
Since orphan instances appear to already have been working, I didn't
do anything there.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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
|
|
|
|
| |
This exports fixities for more things, including class methods and
type-level operators.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
'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.
|
|
|
|
|
|
|
|
| |
* Fix minimal pragma handling
Class declarations contain 'ClassOpSig' not 'Typesig'. This should fix #834.
* Accept html-test output
|
| |
|
| |
|
|
|
|
|
| |
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').
|
|
|
| |
This prevents spurious lines from appearing in the final output.
|
|
|
| |
Fixes parts 1 and 2 of #806.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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
|
| |
|
| |
|
| |
|
|
|
| |
No more clicking to figure out whether your bytestring is strict or lazy!
|
| |
|
|
|
|
|
|
| |
Links to pattern synonyms are now generated, as well as links from
modules in import lists.
Fixes #731.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
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.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add table examples
* Add table types and adopt simple parser
Simple parser is done by Giovanni Cappellotto (@potomak)
in https://github.com/haskell/haddock/pull/577
It seems to support single fine full tables, so far from full
RST-grid tables, but it's good start.
Table type support row- and colspans, but obviously parser is lacking.
Still TODO:
- Latex backend. Should we use multirow package
https://ctan.org/pkg/multirow?lang=en?
- Hoogle backend: ?
* Implement grid-tables
* Refactor table parser
* Add two ill-examples
* Update CHANGES.md
* Basic documentation for tables
* Fix documentation example
|
|
|
|
| |
See #579. This just adds an <a> tag around the heading, pointing to the
heading itself.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Start changing to use GHC lexer
* better cpp
* Change SrcSpan to RealSrcSpan
* Remove error
* Try to stop too many open files
* wip
* wip
* Revert "wip"
This reverts commit b605510a195f26315e3d8ca90e6d95a6737553e1.
Conflicts:
haddock-api/haddock-api.cabal
haddock-api/src/Haddock/Interface.hs
* Remove pointless 'caching'
* Use dlist rather than lists when finding vars
* Use a map rather than list
* Delete bogus comment
* Rebase followup
Things now run using the GHC lexer. There are still
- stray debug statements
- unnecessary changes w.r.t. master
* Cleaned up differences w.r.t. current Haddock HEAD
Things are looking good. quasiquotes in particular look beautiful: the
TH ones (with Haskell source inside) colour/link their contents too!
Haven't yet begun to check for possible performance problems.
* Support CPP and top-level pragmas
The support for these is hackier - but no more hacky than the existing
support.
* Tests pass, CPP is better recognized
The tests were in some cases altered: I consider the new output to be more
correct than the old one....
* Fix shrinking of source without tabs in test
* Replace 'Position'/'Span' with GHC counterparts
Replaces 'Position' -> 'GHC.RealSrcLoc' and 'Span' -> 'GHC.RealSrcSpan'.
* Nits
* Forgot entry in .cabal
* Update changelog
|
|
|
|
| |
This reverts commit 01eeeb048acd2dd05ff6471ae148a97cf0720547.
|
|
|
|
| |
This reverts commit 9f054dc365379c66668de6719840918190ae6e44.
|
|
|
|
| |
This reverts commit 134a7bb054ea730b13c8629a76232d73e3ace049.
|
| |
|
| |
|
| |
|
|\ |
|
| | |
|
| | |
|
| |
| |
| |
| | |
Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Remove unnecessary call to 'collapseSection'
The call is unnecessary since there is no corresponding toggle for hiding the
section of orphan instances.
* Use <details> for collapsibles
This makes them work even when JS is disabled. Closes #560.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Overhaul Haddock's rendering of kind signatures
* Strip off kind signatures when specializing
As an added bonus, this lets us remove an ugly hack specifically for `(->)`.
Yay!
* Update due to 0390e4a0f61e37bd1dcc24a36d499e92f2561b67
* @alexbiehl's suggestions
* Import injectiveVarsOfBinder from GHC
|
| | |
|
|\ \
| |/
|/| |
|
| | |
|
| | |
|
| |\ |
|
| | | |
|
| | |
| | |
| | |
| | | |
See https://ghc.haskell.org/trac/ghc/wiki/ImplementingTreesThatGrow
|
| | |
| | |
| | |
| | |
| | |
| | | |
I forgot a conditional, oops!
Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
|