[project @ 2003-01-09 15:42:27 by simonpj]
authorsimonpj <unknown>
Thu, 9 Jan 2003 15:42:27 +0000 (15:42 +0000)
committersimonpj <unknown>
Thu, 9 Jan 2003 15:42:27 +0000 (15:42 +0000)
commitdc7c699d792bf115a1f3192db15179d7bd461957
treecc061ae58845f281b43a7fe94a55481b77004e43
parent661d29564f24a7b19a6c42299461fd8db4922a3f
[project @ 2003-01-09 15:42:27 by simonpj]
---------------------------------------
Improvements to the byte-code generator
---------------------------------------

1. The schemeR call in coreExprToBCOs was bogusly passing a bunch of free
   variables, when the set should always be empty. As a result, compiling
   an expression with an unbound free variable (e.g. 'x + 1', where 'x' is
   entirely unbound) succeeded, expecting 'x' to be passed on the stack,
   which of course it won't be.

   This bug only shows up if an earlier stage of the compiler goes wrong,
   but fixing turns a seg-fault into a more graceful failure.

2. Make schemeE allocate non-recursive constructors directly.

3. Lots of general tidying up.  Result is 50 lines shorter than before.
ghc/compiler/ghci/ByteCodeGen.lhs