Mention no field name for newtypes in autodoc
Clarification and motivation
When implementing TypeHasDoc
instance for newtypes, one has to make sure that he uses haskellRepNoFields
, otherwise field name (unMyType
) will be retained and in most cases this is not what we want.
I somehow missed the fact that we can do this for newtype automatically, we only need to check that in the corresponding Generics instance.
Acceptance criteria
- Field names are removed automatically.
- Unnecessary
haskellRepNoFields
calls are removed. - A function is implemented which has a signature similar to
haskellRepNoField
and which assigns given name to a type representation of a newtype.