Only pretty-print binders in closed type families with -fprint-explicit-foralls
authorRyan Scott <ryan.gl.scott@gmail.com>
Tue, 25 Apr 2017 22:38:34 +0000 (18:38 -0400)
committerBen Gamari <ben@smart-cactus.org>
Tue, 25 Apr 2017 22:39:51 +0000 (18:39 -0400)
commitda792e47981f65b2dba4fc76ce51dc3fb9c4c02d
treeb962d875d058c6db652dfc681debcb0a9dcd7b80
parent71c3cea60c74054b6ba9ed918a58814aa91e01c2
Only pretty-print binders in closed type families with -fprint-explicit-foralls

Previously, we were unconditionally pretty-printing all type variable
binders when pretty-printing closed type families (e.g., in the output
of `:info` in GHCi). This threw me for a loop, so let's guard this behind
the `-fprint-explicit-foralls` flag.

Test Plan: make test TEST=T13420

Reviewers: goldfire, austin, bgamari

Reviewed By: bgamari

Subscribers: rwbarton, thomie

GHC Trac Issues: #13420

Differential Revision: https://phabricator.haskell.org/D3497
compiler/iface/IfaceSyn.hs
testsuite/tests/backpack/should_fail/bkpfail42.stderr
testsuite/tests/ghci/scripts/T13420.hs [new file with mode: 0644]
testsuite/tests/ghci/scripts/T13420.script [new file with mode: 0644]
testsuite/tests/ghci/scripts/T13420.stdout [new file with mode: 0644]
testsuite/tests/ghci/scripts/T7939.stdout
testsuite/tests/ghci/scripts/all.T
testsuite/tests/partial-sigs/should_compile/NamedWildcardInTypeFamilyInstanceLHS.stderr