[Haddock] [haddock] #179: Reusing named chunks in other modules

haddock haddock at projects.haskell.org
Mon Sep 12 00:48:58 BST 2011

#179: Reusing named chunks in other modules
Reporter:  reinerp      |       Owner:        
    Type:  enhancement  |      Status:  new   
Priority:  major        |   Milestone:  2.10.0
 Version:  2.9.2        |    Keywords:        
 Similar to #97. Consider the following:

 module A (
   -- $note

   -- $note
   -- This is a long note.

   -- | This is a function
   f :: Int -> Int
   f x = x

 module B (
   -- $A.note

   import A

 Currently, there is no way to insert the documentation chunk named
 {{{$note}}} (which is defined in module {{{A}}}) into the documentation
 for {{{B}}}. I propose the above syntax as a way to do this.

 The motivation for this construct is as follows. Since {{{A}}} and {{{B}}}
 export (at least some of) the same API, the {{{$note}}} chunk should be
 included in both of their Haddocks. It is possible to work around this
 need by using anchors to link to {{{A}}}'s note from {{{B}}}, but this a
 workaround rather than a solution.

Ticket URL: <http://trac.haskell.org/haddock/ticket/179>
haddock <http://www.haskell.org/haddock>
Haddock, The Haskell Documentation Tool

More information about the Haddock mailing list