| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Patch to allow simple hyperlinking to an arbitrary location in another
module's documentation, from Volker Stolz.
Now in a doc comment:
#foo#
creates
<a name="foo"></a>
And you can use the form "M\#foo" to hyperlink to the label 'foo' in
module 'M'. Note that the backslash is necessary for now.
|
|
|
|
|
|
|
|
|
|
|
| |
Make the markup syntax a little more friendly:
- single quotes are now interpreted literally unless they surround a
valid Haskell identifier. So for example now there's no need to
escape a single quote used as an apostrophe.
- text to the right of a bird track is now literal (if you want
marked-up text in a code block, use @...@).
|
|
|
|
| |
Back out previous change until we can find a better way to do this.
|
|
|
|
|
|
|
|
|
| |
Handle lone occurrences of '/', e.g.,
-- | This/that.
[did this in the lexer rather than in the parser, as I couldn't
see a way not to introduce an S/R conflict that way.]
|
|
|
|
| |
If an identifier doesn't lex, then just replace it by a DocString.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reworking of the internals to support documenting function arguments
(the Most Wanted new feature by the punters).
The old method of keeping parsed documentation in a Name -> Doc
mapping wasn't going to cut it for anntations on type components,
where there's no name to attach the documentation to, so I've moved to
storing all the documentation in the abstract syntax. Previously some
of the documentation was left in the abstract syntax by the parser,
but was later extracted into the mapping.
In order to avoid having to parameterise the abstract syntax over the
type of documentation stored in it, we have to parse the documentation
at the same time as we parse the Haskell source (well, I suppose we
could store 'Either String Doc' in the HsSyn, but that's clunky). One
upshot is that documentation is now parsed eagerly, and documentation
parse errors are fatal (but have better line numbers in the error
message).
The new story simplifies matters for the code that processes the
source modules, because we don't have to maintain the extra Name->Doc
mapping, and it should improve efficiency a little too.
New features:
- Function arguments and return values can now have doc annotations.
- If you refer to a qualified name in a doc string, eg. 'IO.putStr',
then Haddock will emit a hyperlink even if the identifier is not
in scope, so you don't have to make sure everything referred to
from the documentation is imported.
- several bugs & minor infelicities fixed.
|
|
|
|
|
|
|
| |
Allow backquote as the right-hand quote as well as the left-hand
quote, as suggested by Dean Herrington.
Clean up the grammar a litte.
|
|
|
|
|
|
|
|
|
|
| |
Change the markup for typewriter-font from [...] to @...@. The
reasoning is that the '@' symbol is much less likely to be needed than
square brackets, and we don't want to have to escape square brackets
in code fragments.
This will be mildly painful in the short term, but it's better to get
the change out of the way as early as possible.
|
|
|
|
| |
Allow code blocks to be denoted with bird-tracks in addition to [...].
|
|
|
|
| |
Be more lenient about extra paragraph breaks
|
|
|
|
|
| |
Add missing type signature (a different workaround for the bug in
GHC's simplifier).
|
|
|
|
|
|
|
| |
- support for fundeps (partially contributed by Brett Letner - thanks
Brett).
- make it build with GHC 4.08.2
|
|
|
|
|
|
| |
Parse errors in doc strings are now reported as warnings rather that
causing the whole thing to fall over. It still needs cleaning up (the
warning is emitted with trace) but this will do for the time being.
|
|
|
|
|
| |
Lex URLs as a single token to avoid having to escape special
characters inside the URL string.
|
|
|
|
|
|
|
|
| |
- add the <...> syntax for marking up URLs in documentation
- Make the output for data & class declarations more compact when
there aren't any documentation annotations on the individual
methods or constructors respectively.
|
|
forgot one file
|