
#13637: Printing type operators adds extraneous parenthesis -------------------------------------+------------------------------------- Reporter: darchon | Owner: alanz Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.2.1-rc2 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by alanz): I am investigating this, and suspect I may not be the culprit, it deals directly with `Type`, and the printing process goes through `pprTypeForUser ty` which is {{{#!haskell pprTypeForUser :: Type -> SDoc -- The type is tidied pprTypeForUser ty = pprSigmaType tidy_ty where (_, tidy_ty) = tidyOpenType emptyTidyEnv ty -- Often the types/kinds we print in ghci are fully generalised -- and have no free variables, but it turns out that we sometimes -- print un-generalised kinds (eg when doing :k T), so it's -- better to use tidyOpenType here }} And in turn `tidyOpenType` ends up in `tidyOpenTypes`, which changed as a result of https://github.com/ghc/ghc/commit/e9bf7bb5cc9 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13637#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler