Fix SigTvs at the kind level
authorSimon Peyton Jones <simonpj@microsoft.com>
Mon, 11 Dec 2017 15:53:32 +0000 (15:53 +0000)
committerSimon Peyton Jones <simonpj@microsoft.com>
Mon, 11 Dec 2017 17:35:14 +0000 (17:35 +0000)
commit8361b2c5a9f7a00f0024f44a43b851998ae41e33
treeaca531ea806d9f22533f543f13f85828e48aa1df
parent8b36ed129652df07af22b5e2a2e57b1df8cfbbc9
Fix SigTvs at the kind level

This patch fixes two bugs in the treatment of SigTvs at the
kind level:

- We should always generalise them, never default them
  (Trac #14555, #14563)

- We should check if they get unified with each other
  (Trac #11203)

Both are described in TcHsType
   Note [Kind generalisation and SigTvs]
15 files changed:
compiler/typecheck/TcBinds.hs
compiler/typecheck/TcHsType.hs
compiler/typecheck/TcMType.hs
compiler/typecheck/TcSimplify.hs
compiler/typecheck/TcTyClsDecls.hs
compiler/typecheck/TcType.hs
compiler/types/TyCon.hs
testsuite/tests/polykinds/T11203.hs [new file with mode: 0644]
testsuite/tests/polykinds/T11203.stderr [new file with mode: 0644]
testsuite/tests/polykinds/T11821a.stderr [new file with mode: 0644]
testsuite/tests/polykinds/T14555.hs [new file with mode: 0644]
testsuite/tests/polykinds/T14555.stderr [new file with mode: 0644]
testsuite/tests/polykinds/T14563.hs [new file with mode: 0644]
testsuite/tests/polykinds/T14563.stderr [new file with mode: 0644]
testsuite/tests/polykinds/all.T