Ticket #50 (closed defect: fixed)

Opened 6 years ago

Last modified 22 months ago

Non-recognised declarations can "get in the way" of Haddock comments being recognised

Reported by: waern Owned by:
Priority: major Milestone:
Version: 2.1.0 Keywords:
Cc:

Description

Pragmas and other non-recognised declarations can stop Haddock commentation being recognised.

e.g. This is undocumented in the resulting haddock ("A comment" is missing).

-- | A comment.
{-# INLINE genVennAsList #-}
genVennAsList :: (a -> b -> COrdering c) -> AVL a -> AVL b -> (AVL a, [c], AVL b)
genVennAsList cmp = genVennToList cmp []

.. but this is OK

-- | A comment.
genVennAsList :: (a -> b -> COrdering c) -> AVL a -> AVL b -> (AVL a, [c], AVL b)
{-# INLINE genVennAsList #-}
genVennAsList cmp = genVennToList cmp []

Change History

Changed 6 years ago by waern

Reported by Adrian Hey.

Changed 6 years ago by waern

The problem here is that we match up Haddock comments with their declarations by going through a list of all declarations and matching using SrcLoc?'s. This would work perfectly if the list of all declarations actually contained all declarations :) Currently it only contains those types of delcarations that we care about in Haddock. The fix should be easy to implement.

Changed 6 years ago by anonymous

  • milestone 2.3.0 deleted

Changed 6 years ago by wren ng thornton

Changed 6 years ago by waern

  • milestone set to 2.4.2

Will try to get this into the next release.

Changed 6 years ago by waern

  • status changed from new to closed
  • resolution set to fixed

Changed 22 months ago by anonymous

  • milestone 2.4.2 deleted

Milestone 2.4.2 deleted

Note: See TracTickets for help on using tickets.