Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Haddock always shows kind signatures for types re-exported from other packages #548

Closed
gridaphobe opened this issue Aug 17, 2016 · 1 comment

Comments

@gridaphobe
Copy link
Contributor

If I run haddock on the following modules

module Foo where

data Foo = MkFoo
module Bar (Bar(..), Foo(..)) where

import Foo

data Bar = MkBar

the types are formatted as expected, without kind-signatures.

However, if I move Foo into a separate package it suddenly has a kind-signature in the Bar haddocks.

It would be nice if haddock would only display kind signatures when one of the type parameters has a non-* kind, otherwise it's just noise IMO.

@ezyang
Copy link
Contributor

ezyang commented Mar 13, 2017

The reason for this problem is probably because Haddock is reverse engineering the source declaration from the recorded type in the GHC interface file, and then forgetting to suppress kinds (when you have it directly, it just uses the renamed source directly.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants