Closed jorisdral closed 6 months ago
Might be related to https://github.com/haskell/haddock/issues/1608?
Hi, thank you for this ticket, but Haddock now lives full-time in the GHC repository! Read more at https://discourse.haskell.org/t/haddock-now-lives-in-the-ghc-repository/9576.
Let me know if you feel it is still needed, and I'll migrate it. :)
I found that a hyperlink to an associated type links to its class instead of the associated type if the type name is ambiguous. I noticed this when I was looking at the documentation of
generics-sop
. In particular, I saw thatGeneric
is rendered in the docs for deriveGeneric instead ofCode
.Code
is an associated type of the classGeneric
, andCode
is ambiguous (the name is defined in a TH module as well).The following is a minimal example. I was able to reproduce the bug with that example on
ghc-9.2.8
,ghc-9.4.7
, andghc-9.6.3
, but it's not a problem onghc-8.10.7
.Minimal example
```haskell module A where data T ``` ```haskell {-# LANGUAGE TypeFamilies #-} module B where class B where type T ```` ```haskell module Main where import A import B -- | 'T' should be rendered as @T@ main :: IO () main = pure () ```