diff options
| author | simonpj@microsoft.com <unknown> | 2010-09-13 09:50:48 +0000 |
|---|---|---|
| committer | simonpj@microsoft.com <unknown> | 2010-09-13 09:50:48 +0000 |
| commit | d2ce0f52d42edf32bb9f13796e6ba6edba8bd516 (patch) | |
| tree | 1a0792f7eb186fa3d71a02f4a21da3daae3466bb /compiler/cmm/CmmCPSZ.hs | |
| parent | 0084ab49ab3c0123c4b7f9523d092af45bccfd41 (diff) | |
| download | haskell-d2ce0f52d42edf32bb9f13796e6ba6edba8bd516.tar.gz | |
Super-monster patch implementing the new typechecker -- at last
This major patch implements the new OutsideIn constraint solving
algorithm in the typecheker, following our JFP paper "Modular type
inference with local assumptions".
Done with major help from Dimitrios Vytiniotis and Brent Yorgey.
Diffstat (limited to 'compiler/cmm/CmmCPSZ.hs')
| -rw-r--r-- | compiler/cmm/CmmCPSZ.hs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/compiler/cmm/CmmCPSZ.hs b/compiler/cmm/CmmCPSZ.hs index 8bcadbb122..e72d3f2da9 100644 --- a/compiler/cmm/CmmCPSZ.hs +++ b/compiler/cmm/CmmCPSZ.hs @@ -1,3 +1,7 @@ +{-# OPTIONS_GHC -XNoMonoLocalBinds #-} +-- Norman likes local bindings +-- If this module lives on I'd like to get rid of this flag in due course + module CmmCPSZ ( -- | Converts C-- with full proceedures and parameters -- to a CPS transformed C-- with the stack made manifest. @@ -153,7 +157,10 @@ cpsTop hsc_env (CmmProc h l args (stackInfo@(entry_off, _), g)) = where dflags = hsc_dflags hsc_env mbpprTrace x y z = if dopt Opt_D_dump_cmmz dflags then pprTrace x y z else z dump f txt g = dumpIfSet_dyn dflags f txt (ppr g) + + run :: FuelMonad a -> IO a run = runFuelIO (hsc_OptFuel hsc_env) + dual_rewrite flag txt pass g = do dump flag ("Pre " ++ txt) g g <- run $ pass g |
