summaryrefslogtreecommitdiff
path: root/validate
diff options
context:
space:
mode:
authorsimonpj@microsoft.com <unknown>2009-03-30 08:49:12 +0000
committersimonpj@microsoft.com <unknown>2009-03-30 08:49:12 +0000
commit59fa6266f00b6edcfc20c491c8de9a1b215dfa22 (patch)
treeec66c2b33328d51da9fe6bafc8e9c0616c306cea /validate
parent21eea25f1212ec306aac806233a2ec048212d529 (diff)
downloadhaskell-59fa6266f00b6edcfc20c491c8de9a1b215dfa22.tar.gz
Fix an nasty black hole, concerning computation of isRecursiveTyCon
Fixing #246 (pattern-match order in record patterns) made GHC go into a black hole, by changing the order of patterm matching in TyCon.isProductTyCon! It turned out that GHC had been avoiding the black hole only by the narrowest of margins up to now! The black hole concerned the computation of which type constructors are recursive, in TcTyDecls.calcRecFlags. We now refrain from using isProductTyCon there, since it triggers the black hole (very indirectly). See the "YUK YUK" comment in the body of calcRecFlags. As it turns out, the fact that TyCon.isProductTyCon matched on the algTcRec field was quite redundant, so I removed that too. However, without the fix to calcRecFlags, this wouldn't fix the black hole because of the use of isRecursiveTyCon in BuildTyCl.mkNewTyConRhs. Anyway, it's fine now.
Diffstat (limited to 'validate')
0 files changed, 0 insertions, 0 deletions