diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2014-06-03 14:15:52 +0100 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2014-06-03 14:24:08 +0100 |
commit | b4856f9f4f0fb3db473901b247d3fa94a11c25a0 (patch) | |
tree | 64512fff57acca9baf54d0e72d516679763711a9 /testsuite/tests/ghci/scripts/T5417.stdout | |
parent | da64c97f1c0b147ea80a34fe64fe947ba7820c00 (diff) | |
download | haskell-b4856f9f4f0fb3db473901b247d3fa94a11c25a0.tar.gz |
Do pretty-printing of TyThings via IfaceDecl (Trac #7730)
All the initial work on this was done fy 'archblob' (fcsernik@gmail.com);
thank you!
I reviewed the patch, started some tidying, up and then ended up in a huge
swamp of changes, not all of which I can remember now. But:
* To suppress kind arguments when we have -fno-print-explicit-kinds,
- IfaceTyConApp argument types are in a tagged list IfaceTcArgs
* To allow overloaded types to be printed with =>, add IfaceDFunTy to IfaceType.
* When printing data/type family instances for the user, I've made them
print out an informative RHS, which is a new feature. Thus
ghci> info T
data family T a
data instance T Int = T1 Int Int
data instance T Bool = T2
* In implementation terms, pprIfaceDecl has just one "context" argument,
of type IfaceSyn.ShowSub, which says
- How to print the binders of the decl
see note [Printing IfaceDecl binders] in IfaceSyn
- Which sub-comoponents (eg constructors) to print
* Moved FastStringEnv from RnEnv to OccName
It all took a ridiculously long time to do. But it's done!
Diffstat (limited to 'testsuite/tests/ghci/scripts/T5417.stdout')
-rw-r--r-- | testsuite/tests/ghci/scripts/T5417.stdout | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/testsuite/tests/ghci/scripts/T5417.stdout b/testsuite/tests/ghci/scripts/T5417.stdout index 73d1de932d..1085a1750f 100644 --- a/testsuite/tests/ghci/scripts/T5417.stdout +++ b/testsuite/tests/ghci/scripts/T5417.stdout @@ -6,4 +6,4 @@ class C.C1 a where type role C.F nominal data family C.F a -- Defined at T5417a.hs:5:5 -data C.F (B1 a) -- Defined at T5417.hs:8:10 +data instance C.F (B1 a) = B2 a -- Defined at T5417.hs:8:10 |