aboutsummaryrefslogtreecommitdiff
path: root/src/Haddock/InterfaceFile.hs
Commit message (Collapse)AuthorAgeFilesLines
* Fix build in GHC treeIan Lynagh2010-07-301-1/+1
|
* Style police in Haddock.InterfaceFileDavid Waern2010-07-211-12/+12
|
* Fix a few stylistic issues in H.InterfaceFileDavid Waern2010-05-131-2/+9
|
* Position the module header the same way everywhereDavid Waern2010-05-131-1/+0
| | | | Silly, but nice with some consistency :-)
* Add markup support for interactive examplessimon.hengel2010-04-021-0/+16
|
* Rename HsDoc back into DocDavid Waern2009-11-281-1/+1
|
* Remove cruft due to compatibility with older GHCsDavid Waern2009-11-281-5/+1
|
* Fix building with GHC >= 6.12Ian Lynagh2009-09-221-0/+6
|
* Use Map.fromList/toList intead of fromAscList/toAscList when serializing MapsDavid Waern2009-09-111-2/+2
| | | | | | | This fixes the missing docs problem. The Eq and Ord instances for Name uses the unique number in Name. This number is created at deserialization time by GHC's magic Binary instance for Name, and it is random. Thus, fromAscList can't be used at deserialization time, even though toAscList was used at serialization time.
* Follow changes in GHC's interface file formatSimon Marlow2009-08-241-4/+4
| | | | Word32 instead of Int for FastString and Name offsets
* InterfaceFile: ghc >= 6.10Isaac Dupree2009-08-231-28/+0
|
* cross-package fnArgDocs. WARNING: changes .haddock binary formatIsaac Dupree2009-08-231-8/+15
| | | | | | | | | | | | | | | | While breaking the format, I took the opportunity to unrename the DocMap that's saved to disk, because there's really no reason that we want to know what *another* package's favorite place to link a Name to was. (Is that true? Or might we want to know, someday?) Also, I added instance Binary Map in InterfaceFile. It makes the code a little simpler without changing anything of substance. Also it lets us add another Map hidden inside another Map (fnArgsDocs in instDocMap) without having really-convoluted serialization code. Instances are neat! I don't understand why this change to InterfaceFile seemed to subtly break binary compatibility all by itself, but no matter, I'll just roll it into the greater format-changing patch. Done!
* Do not version .haddock file based on GHC patchlevel versionDavid Waern2009-08-141-18/+5
| | | | | We require that the instances of Binary that we use from GHC will not change between patchlevel versions.
* Version .haddock files made with GHC 6.10.3/4 correcltyDavid Waern2009-08-141-6/+6
|
* Fix unused import warningsIan Lynagh2009-07-071-5/+0
|
* Add Haddock module headersDavid Waern2009-06-241-5/+10
| | | | | | | | | Add a proper Haddock module header to each module, with a more finegrained copyright. If you feel mis-accreditted, please correct any copyright notice! The maintainer field is set to haddock@projects.haskell.org. Next step is to add a brief description to each module.
* -Wall policeDavid Waern2009-03-271-1/+1
|
* Remove H.DocName and put DocName in H.TypesDavid Waern2009-03-271-1/+23
|
* Bump .haddock file version number (due to change of format)David Waern2009-03-211-5/+11
|
* Typo in commentJoachim Breitner2009-02-201-1/+1
|
* Show re-exported names from external packages againDavid Waern2009-01-021-2/+6
| | | | | | | This fixes GHC ticket 2746. In order to also link to the exported subordinate names of a declaration, we need to re-introduce the sub map in the .haddock files.
* Store hidden modules in .haddock filesDavid Waern2008-11-151-5/+7
| | | | | | | | | | | | | We store documentation for an entity in the 'InstalledInterface' of the definition site module, and never in the same structure for a module which re-exports the entity. So when a client of the Haddock library wants to look up some documentation, he/she might need to access a hidden module. But we currently don't store hidden modules in the .haddock files. So we add the hidden modules and the Haddock options to the .haddock files. The options will be used to filter the module list to obtain the visible modules only, which is necessary for generating the contents and index for installed packages.
* Fix warnings in H.InterfaceFile and H.OptionsDavid Waern2008-11-061-1/+2
|
* WibbleDavid Waern2008-10-221-0/+1
|
* Add back .haddock file versioning based on GHC versionDavid Waern2008-10-101-0/+9
| | | | It was accidentally removed in the patch for GHC 6.8.2 compatibility
* Make Haddock build with GHC 6.8.2David Waern2008-10-101-10/+13
|
* Port Haddock.Interface to new GHC API.Thomas Schilling2008-09-151-42/+60
| | | | | | | | | | | | | | | | This required one bigger change: 'readInterfaceFile' used to take an optional 'Session' argument. This was used to optionally update the name cache of an existing GHC session. This does not work with the new GHC API, because an active session requires the function to return a 'GhcMonad' action, but this is not possible if no session is provided. The solution is to use an argument of functions for reading and updating the name cache and to make the function work for any monad that embeds IO, so it's result type can adapt to the calling context. While refactoring, I tried to make the code a little more self-documenting, mostly turning comments into function names.
* Fix some warningsIan Lynagh2008-08-271-51/+55
|
* Follow changes to Binary in GHC 6.9David Waern2008-08-131-1/+78
|
* Make our .haddock file version number depend on the GHC versionDavid Waern2008-08-121-1/+17
| | | | | | We need to do this, since our .haddock format can potentially change whenever GHC's version changes (even when only the patchlevel changes).
* Remove claim of backwards compatibility from docs for readInterfaceFileDavid Waern2008-05-011-2/+0
|
* Fix some trivial warnings in H.InterfaceFileDavid Waern2008-02-101-4/+7
|
* Change the representation of DocNamesDavid Waern2008-02-091-21/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ross Paterson reported a bug where links would point to the defining module instead of the "best" module for an identifier (e.g Int pointing to GHC.Base instead of Data.Int). This patch fixes this problem by refactoring the way renamed names are represented. Instead of representing them by: > data DocName = Link Name | NoLink Name they are now represented as such: > data DocName = Documented Name Module | Undocumented Name and the the link-env looks like this: > type LinkEnv = Map Name Module There are several reasons for this. First of all, the bug was caused by changing the module part of Names during the renaming process, without changing the Unique field. This caused names to be overwritten during the loading of .haddock files (which caches names using the NameCache of the GHC session). So we might create new Uniques during renaming to fix this (but I'm not sure that would be problem-free). Instead, we just keep the Name and add the Module where the name is best documented, since it can be useful to keep the original Name around (for e.g. source-code location info and for users of the Haddock API). Also, the names Link/NoLink don't really make sense, since wether to use links or not is entirely up to the users of DocName. In the process of following this change into H.Backends.Html I removed the assumption that binder names are Undocumented (which was just an unnecessary assumption, the OccName is the only thing needed to render these). This will probably make it possible to get rid of the renamer and replace it with a traversal from SYB or Uniplate. Since DocName has changed, InterfaceFile has changed so this patch also increments the file-format version. No backwards-compatibility is implemented.
* Add documentation for readInterfaceFileDavid Waern2008-01-071-1/+5
|
* Don't require -B <ghc-libdir> when no argument filesDavid Waern2007-11-111-8/+18
| | | | | | Change readInterfaceFile to take a Maybe Session, to avoid having to pass -B <ghc-libdir> to Haddock when there're no source files to process. This is nice when computing contents/index for external packages.
* Introduce InstalledInterface structure and add more stuff to the .haddock filesDavid Waern2007-11-101-26/+190
| | | | | | | We introduce InstalledInterface capturing the part of Interface that is stored in the interface files. We change the ppHtmlContents and ppHtmllIndex to take this structure instead of a partial Interface. We add stuff like the doc map and exported names to the .haddock file (via InstalledInterface).
* Synch loading of names from .haddock files with GHC's name cacheDavid Waern2007-11-081-8/+12
|
* Refactoring -- get rid of Haddock.PackagesDavid Waern2007-10-181-34/+38
|
* Add support for --read-interface againDavid Waern2007-10-181-6/+10
|
* Rename HaddockModule to InterfaceDavid Waern2007-08-301-5/+5
|
* Major refactoringDavid Waern2007-08-291-1/+1
|
* Add top module comment to all filesDavid Waern2007-08-171-0/+8
|
* Fix conflictsDavid Waern2007-07-111-1/+1
|
* update to compile with the latest GHC & CabalSimon Marlow2007-05-301-2/+3
|
* Follow changes to record constructor representationDavid Waern2007-07-111-1/+1
|
* Do save/read of interface files properlydavve@dtek.chalmers.se2007-04-051-22/+167
|
* De-flatten the namespacedavve@dtek.chalmers.se2007-03-251-1/+1
|
* Start work on Haddock APIdavve@dtek.chalmers.se2007-03-251-0/+50