X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2FsimplCore%2FLiberateCase.lhs;h=02a3fab567d6865ac1a8d3d784a0e64c58e0321f;hp=31063d3b2491b7a32fd859137fc8904aefa32cdd;hb=b1ab4b8a607addc4d097588db5761313c996a41f;hpb=7aa3f5247ae454b10b61e2f28a9431f0889a8cff diff --git a/compiler/simplCore/LiberateCase.lhs b/compiler/simplCore/LiberateCase.lhs index 31063d3..02a3fab 100644 --- a/compiler/simplCore/LiberateCase.lhs +++ b/compiler/simplCore/LiberateCase.lhs @@ -23,7 +23,6 @@ import Coercion import TyCon import VarEnv import Name ( localiseName ) -import Outputable import Util ( notNull ) import Data.IORef ( readIORef ) \end{code} @@ -90,7 +89,7 @@ Consider this: f = \ t -> case (v `cast` co) of V a b -> a : f t -Exactly the same optimistaion (unrolling one call to f) will work here, +Exactly the same optimisation (unrolling one call to f) will work here, despite the cast. See mk_alt_env in the Case branch of libCase. @@ -108,7 +107,6 @@ big. Data types ~~~~~~~~~~ - The ``level'' of a binder tells how many recursive defns lexically enclose the binding A recursive defn "encloses" its RHS, not its @@ -411,7 +409,7 @@ data LibCaseEnv initEnv :: DynFlags -> FamInstEnvs -> LibCaseEnv initEnv dflags fams - = LibCaseEnv { lc_size = libCaseThreshold dflags, + = LibCaseEnv { lc_size = specThreshold dflags, lc_lvl = 0, lc_lvl_env = emptyVarEnv, lc_rec_env = emptyVarEnv,