[project @ 2003-06-02 13:28:08 by simonpj]
authorsimonpj <unknown>
Mon, 2 Jun 2003 13:28:09 +0000 (13:28 +0000)
committersimonpj <unknown>
Mon, 2 Jun 2003 13:28:09 +0000 (13:28 +0000)
commit663a01b260eb7a2e14cc943524931f4147cd523a
treefa34a758167fdd098ee11f3ade1f329a20115ca9
parent7849d4a5be50796cda506c5d92ca2ccb0d15dd90
[project @ 2003-06-02 13:28:08 by simonpj]
-------------------------------------
      Fix the big-tuple-from-desugaring problem
-------------------------------------

The desugarer generates a tuple from
- mutually recursive bindings
- pattern bindings

If either bind a lot of variables, GHC can generate a big
tuple that isn't in the library, with subsequent disaster.

This commit fixes the problem, by using nested tuples.  It
does *not* fix the problem with big tuples written by the
user. And there's still a potential desugarer problem with
parallel list comprehensions that bind a lot of variables
(and parallel array comprehensions) -- but I expect they are
much much rarer.

The fix isn't fully tested yet -- I'll try to do that today.
ghc/compiler/deSugar/DsListComp.lhs
ghc/compiler/deSugar/DsUtils.lhs