Haddock comments on infix constructors (#24221)
Rewrite the HasHaddock
instance for ConDecl GhcPs
to account for infix constructors.
This change fixes a Haddock regression (introduced in 19e80b9a) that affected leading comments on infix data constructor declarations:
-- | Docs for infix constructor
| Int :* Bool
The comment should be associated with the data constructor (:*)
, not with its left-hand side Int
.