aboutsummaryrefslogtreecommitdiff
path: root/src/Main.hs
Commit message (Collapse)AuthorAgeFilesLines
...
* [haddock @ 2004-08-10 14:33:45 by simonmar]simonmar2004-08-101-2/+3
| | | | Fixes to installation under Windows.
* [haddock @ 2004-08-09 11:55:05 by simonmar]simonmar2004-08-091-36/+107
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for a short description for each module, which is included in the contents. The short description should be given in a "Description: " field of the header. Included in this patch are changes that make the format of the header a little more flexible. From the comments: -- all fields in the header are optional and have the form -- -- [spaces1][field name][spaces] ":" -- [text]"\n" ([spaces2][space][text]"\n" | [spaces]"\n")* -- where each [spaces2] should have [spaces1] as a prefix. -- -- Thus for the key "Description", -- -- > Description : this is a -- > rather long -- > -- > description -- > -- > The module comment starts here -- -- the value will be "this is a .. description" and the rest will begin -- at "The module comment". The header fields must be in the following order: Module, Description, Copyright, License, Maintainer, Stability, Portability. Patches submitted by: George Russell <ger@informatik.uni-bremen.de>, with a few small changes be me, mostly to merge with other recent changes. ToDo: document the module header.
* [haddock @ 2004-08-03 19:45:30 by sof]sof2004-08-031-1/+1
| | | | ffi wibble
* [haddock @ 2004-08-01 19:52:06 by krasimir]krasimir2004-08-011-7/+3
| | | | fix some bugs. Now I have got the entire libraries documentation in HtmlHelp 2.0 format.
* [haddock @ 2004-08-01 15:14:02 by krasimir]krasimir2004-08-011-0/+3
| | | | add missing imports
* [haddock @ 2004-07-30 22:15:45 by krasimir]krasimir2004-07-301-6/+11
| | | | | | | | more stuffs - support for separated compilation of packages - the contents page now uses DHTML TreeView - fixed copyFile bug
* [haddock @ 2004-07-27 22:58:23 by krasimir]krasimir2004-07-271-15/+11
| | | | Add basic support for Microsoft HTML Help 2.0
* [haddock @ 2004-05-28 20:17:55 by mthomas]mthomas2004-05-281-1/+40
| | | | Windows: search for templates in executable directory. Unix: Haddock tries cwd first rather than error if no -l arg.
* [haddock @ 2004-05-25 10:41:46 by simonmar]simonmar2004-05-251-0/+4
| | | | | Complain if -h is used with --gen-index or --gen-contents, because it'll overwrite the new index/contents.
* [haddock @ 2004-05-19 13:10:23 by ross]ross2004-05-191-41/+46
| | | | | | | Make the handling of "deriving" slightly smarter, by ignoring data constructor arguments that are identical to the lhs. Now handles things like data Tree a = Leaf a | Branch (Tree a) (Tree a) deriving ...
* [haddock @ 2004-03-25 10:29:56 by simonmar]simonmar2004-03-251-1/+10
| | | | | | If a name is imported from two places, one hidden and one not, choose the unhidden one to link to. Also, when there's only a hidden module to link to, don't try linking to it.
* [haddock @ 2004-03-25 10:01:42 by simonmar]simonmar2004-03-251-2/+1
| | | | Fix duplicate instance bug
* [haddock @ 2004-03-24 10:10:50 by simonmar]simonmar2004-03-241-19/+13
| | | | | | | | | | mkExportItems fix & simplification: we should be looking at the actual exported names (calculated earlier) to figure out which subordinates of a declaration are exported. This means that if you export a record, and name its fields separately in the export list, the fields will still be visible in the documentation for the constructor.
* [haddock @ 2004-03-22 14:09:03 by simonmar]simonmar2004-03-221-12/+12
| | | | | | | | getReExports was bogus: we should really look in the import_env to find the documentation for an entity which we are re-exporting without documentation. Suggested by: Ross Paterson (patch modified by me).
* [haddock @ 2003-11-12 10:03:39 by simonmar]simonmar2003-11-121-1/+1
| | | | 2002 -> 2003
* [haddock @ 2003-11-10 16:15:18 by simonmar]simonmar2003-11-101-1/+1
| | | | copyright update
* [haddock @ 2003-11-10 15:15:58 by simonmar]simonmar2003-11-101-1/+1
| | | | getReExports: one error case that isn't
* [haddock @ 2003-11-10 14:51:59 by simonmar]simonmar2003-11-101-16/+17
| | | | | Fix for getReExports: take into account names which are not visible because they are re-exported from a different package.
* [haddock @ 2003-11-10 14:41:05 by simonmar]simonmar2003-11-101-8/+29
| | | | | | | | | | | | | | | | | | | | | Re-exporting names from a different package is problematic, because we don't have access to the full documentation for the entity. Currently Haddock just ignores entities with no documentation, but this results in bogus-looking empty documentation for many of the modules in the haskell98 package. So: - the documentation will now just list the name, as a link pointing to the location of the actual documentation. - now we don't attempt to link to these re-exported entities if they are referred to by the current module. Additionally: - If there is no documentation in the current module, include just the Synopsis section (rather than just the documentation section, as it was before). This just looks nicer and was on the TODO list.
* [haddock @ 2003-11-06 16:48:11 by simonmar]simonmar2003-11-061-13/+26
| | | | | | | | | - Include the OptHide setting in the interface, so we don't include hidden modules in the combined index/contents. - Add a -k/--package flag to set the package name for the current set of modules. The package name for each module is now shown in the right-hand column of the contents, in a combined contents page.
* [haddock @ 2003-11-06 12:39:46 by simonmar]simonmar2003-11-061-8/+22
| | | | | | | | | | | | | | | | | | | | | - Add definition lists, marked up like this: -- | This is a definition list: -- -- [@foo@] The description of @foo@. -- -- [@bar@] The description of @bar@. Cunningly, the [] characters are not treated specially unless a [ is found at the beginning of a paragraph, in which case the ] becomes special in the following text. - Add --use-contents and --gen-contents, along the lines of --use-index and --gen-index added yesterday. Now we can generate a combined index and contents for the whole of the hierarchical libraries, and in theory the index/contents on the system could be updated as new packages are added.
* [haddock @ 2003-11-06 10:44:52 by simonmar]simonmar2003-11-061-4/+13
| | | | | | | Include iface_reexported in the .haddock file. This unfortunately bloats the file (40% for base). If this gets to be a problem we can always apply the dictionary trick that GHC uses for squashing .hi files.
* [haddock @ 2003-11-05 17:16:04 by simonmar]simonmar2003-11-051-4/+24
| | | | | | | | | | | | | Support for generating a single unified index for several packages. --use-index=URL turns off normal index generation, causes Index links to point to URL. --gen-index generates an combined index from the specified interfaces. Currently doesn't work exactly right, because the interfaces don't contain the iface_reexported info. I'll need to fix that up.
* [haddock @ 2003-11-05 11:30:52 by simonmar]simonmar2003-11-051-7/+15
| | | | | | | | | - Suppress warnings about unknown imported modules by default. - Add a -v/--verbose flag to re-enable these warnings. The general idea is to suppress the "Warning: unknown module: Prelude" warnings which most Haddock users will see every time, and which aren't terribly useful.
* [haddock @ 2003-11-05 11:22:04 by simonmar]simonmar2003-11-051-30/+49
| | | | | Remove the last of the uses of 'trace' to emit warnings, and tidy up a couple of places where duplicate warnings were being emitted.
* [haddock @ 2003-10-20 17:19:22 by sof]sof2003-10-201-1/+1
| | | | support for i-parameters + zip comprehensions
* [haddock @ 2003-08-27 07:50:02 by panne]panne2003-08-271-30/+28
| | | | | | | | | | | | | | | | | * Made -D a short option for --dump-interface. * Made -m a short option for --ms-help. * Made -n a short option for --no-implicit-prelude. * Made -c a short option for --css. * Removed DocBook options from executable (they didn't do anything), but mark them as reserved in the docs. Note that the short option for DocBook output is now -S (from SGML) instead of -d. The latter is now a short option for --debug. * The order of the Options in the documentation now matches the order printed by Haddock itself. Note: Although changing the names of options is often a bad idea, I'd really like to make the options for the programs in fptools more consistent and compatible to the ones used in common GNU programs.
* [haddock @ 2003-08-26 19:20:55 by panne]panne2003-08-261-3/+4
| | | | Make it *very* clear that we terminate when given a -V/--version flag
* [haddock @ 2003-08-26 19:01:18 by panne]panne2003-08-261-14/+20
| | | | | | | | | Made option handling a bit more consistent with other tools, in particular: Every program in fptools should output * version info on stdout and terminate successfully when -V or --version * usage info on stdout and terminate successfully when -? or --help * usage info on stderr and terminate unsuccessfully when an unknown option is given.
* [haddock @ 2003-07-30 16:05:40 by simonmar]simonmar2003-07-301-15/+37
| | | | | | | | | | | | | | | Rename instances based on the import_env for the module in which they are to be displayed. This should give, in many cases, better links for the types and classes mentioned in the instance head. This involves keeping around the import_env in the iface until the end, because instances are not collected up until all the modules have been processed. Fortunately it doesn't seem to affect performance much. Instance heads are now attached to ExportDecls, rather than the HTML backend passing around a separate mapping for instances. This is a cleanup.
* [haddock @ 2003-07-30 15:04:52 by simonmar]simonmar2003-07-301-46/+59
| | | | | | Pay attention to import specs when building the the import env, as well as the orig env. This may fix some wrong links in documentation when import specs are being used.
* [haddock @ 2003-07-28 14:32:42 by simonmar]simonmar2003-07-281-5/+11
| | | | Update to avoid using hslibs with GHC >= 5.04
* [haddock @ 2003-07-28 13:35:16 by simonmar]simonmar2003-07-281-6/+43
| | | | | | When a module A exports another module's contents via 'module B', then modules which import entities from B re-exported by A should link to B.foo rather than A.foo. See examples/Bug2.hs.
* [haddock @ 2003-04-25 10:50:05 by ross]ross2003-04-251-1/+74
| | | | | | | | | | | | | | | | | | | | | | | | | | | | An 80% solution to generating derived instances. A complete solution would duplicate the instance inference logic, but if a type variable occurs as a constructor argument, then we can just propagate the derived class to the variable. But we know nothing of the constraints on any type variables that occur elsewhere. For example, the declarations data Either a b = Left a | Right b deriving (Eq, Ord) data Ptr a = Ptr Addr# deriving (Eq, Ord) newtype IORef a = IORef (STRef RealWorld a) deriving Eq yield the instances (Eq a, Eq b) => Eq (Either a b) (Ord a, Ord b) => Ord (Either a b) Eq (Ptr a) Ord (Ptr a) (??? a) => Eq (IORef a) The last example shows the limits of this local analysis. Note that a type variable may be in both categories: then we know a constraint, but there may be more, or a stronger constraint, e.g. data Tree a = Node a [Tree a] deriving Eq yields (Eq a, ??? a) => Eq (Tree a)
* [haddock @ 2002-11-13 09:49:46 by simonmar]simonmar2002-11-131-1/+1
| | | | Small bugfix in the --read-interface option parsing from Brett Letner.
* [haddock @ 2002-07-24 09:42:17 by simonmar]simonmar2002-07-241-95/+112
| | | | Patches to quieten ghc -Wall, from those nice folks at Galois.
* [haddock @ 2002-07-23 10:18:46 by simonmar]simonmar2002-07-231-12/+23
| | | | Add a version banner when invoked with -v
* [haddock @ 2002-07-15 09:54:16 by simonmar]simonmar2002-07-151-17/+12
| | | | merge rev. 1.35
* [haddock @ 2002-07-15 09:19:38 by simonmar]simonmar2002-07-151-6/+7
| | | | | | | Fix a bug in mkExportItems when processing a module without an explicit export list. We were placing one copy of a declaration for each binder in the declaration, which for a data type would mean one copy of the whole declaration per constructor or record selector.
* [haddock @ 2002-07-10 10:58:31 by simonmar]simonmar2002-07-101-5/+5
| | | | Sort the options a bit
* [haddock @ 2002-07-10 10:26:11 by simonmar]simonmar2002-07-101-11/+14
| | | | | Tweaks to the MS Help support: the extra files are now only generated if you ask for them (--ms-help).
* [haddock @ 2002-07-09 10:12:51 by simonmar]simonmar2002-07-091-0/+2
| | | | commented-out debugging code
* [haddock @ 2002-07-04 15:26:13 by simonmar]simonmar2002-07-041-14/+25
| | | | More bugfixes to the export handling
* [haddock @ 2002-07-04 14:56:10 by simonmar]simonmar2002-07-041-22/+27
| | | | | | | Clean up the code that constructs the exported declarations, and fix a couple of bugs along the way. Now if you import a class hiding one of the methods, then re-export the class, the version in the documentation will correctly have the appropriate method removed.
* [haddock @ 2002-07-03 16:01:07 by simonmar]simonmar2002-07-031-35/+95
| | | | | | Handle import specs properly, include 'hiding'. Haddock now has a complete implementation of the Haskell module system (more or less; I won't claim it's 100% correct).
* [haddock @ 2002-06-24 14:37:42 by simonmar]simonmar2002-06-241-4/+23
| | | | | | | | | | | | | | When reading an interface, allow a file path offset to be specified which represents the path to the HTML files for the modules specified by that interface. The path may be either relative (to the location of the HTML for this package), or absolute. The syntax is --read-interface=PATH,FILE where PATH is the path to the HTML, and FILE is the filename containing the interface.
* [haddock @ 2002-06-21 15:50:42 by simonmar]simonmar2002-06-211-9/+82
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for reading and writing interface files(!) This turned out to be quite easy, and necessary to get decent hyperlinks between the documentation for separate packages in the libraries. The functionality isn't quite complete yet: for a given package of modules, you'd like to say "the HTML for these modules lives in directory <dir>" (currently they are assumed to be all in the same place). Two new flags: --dump-interface=FILE dump an interface file in FILE --read-interface=FILE read interface from FILE an interface file describes *all* the modules being processed. Only the exported names are kept in the interface: if you re-export a name from a module in another interface the signature won't be copied. This is a compromise to keep the size of the interfaces sensible. Also, I added another useful option: --no-implicit-prelude avoids trying to import the Prelude. Previously this was the default, but now importing the Prelude from elsewhere makes sense if you also read in an interface containing the Prelude module, so Haddock imports the Prelude implicitly according to the Haskell spec.
* [haddock @ 2002-06-20 12:39:01 by simonmar]simonmar2002-06-201-2/+19
| | | | | Add support for a "prologue" - a description for the whole library, placed on the contents page before the module list.
* [haddock @ 2002-06-08 14:03:36 by panne]panne2002-06-081-1/+1
| | | | | | | Tiny workaround for the fact that Haddock currently ignores HsImportSpecs: Let the local_orig_env take precedence. This is no real solution at all, but improves things sometimes, e.g. in my GLUT documentation. :-)
* [haddock @ 2002-06-05 09:05:07 by simonmar]simonmar2002-06-051-6/+7
| | | | | Keep foreign imports when there is no export list (bug reported by Sven Panne).