[project @ 2005-03-16 10:46:32 by simonpj]
authorsimonpj <unknown>
Wed, 16 Mar 2005 10:46:32 +0000 (10:46 +0000)
committersimonpj <unknown>
Wed, 16 Mar 2005 10:46:32 +0000 (10:46 +0000)
Localise the binder for the nested defn in LiberateCase,
to avoid name clashes between top-level names.
Discovered by Laszlo.

Merge to STABLE

ghc/compiler/simplCore/LiberateCase.lhs

index a5aab26..20c012d 100644 (file)
@@ -191,7 +191,7 @@ libCaseBind env (Rec pairs)
        -- processing the rhs with an *un-extended* environment, so
        -- that the same process doesn't occur for ever!
        --
-    extended_env = addRecBinds env [ (setIdNotExported binder, libCase env_body rhs)
+    extended_env = addRecBinds env [ (adjust binder, libCase env_body rhs)
                                   | (binder, rhs) <- pairs ]
 
        -- Two subtle things: