X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Fmain%2FDriverMkDepend.hs;h=fe2d8f3785dc70fd471608d13bc980eae6b355a5;hb=78b72ed1e0ffab668e0d4bb31657942970515e4f;hp=3e35b758e1e31e7f002e10867634fc06c1fa2528;hpb=2909e581ddf0162ad2c113e17a8f19991862b89c;p=ghc-hetmet.git diff --git a/ghc/compiler/main/DriverMkDepend.hs b/ghc/compiler/main/DriverMkDepend.hs index 3e35b75..fe2d8f3 100644 --- a/ghc/compiler/main/DriverMkDepend.hs +++ b/ghc/compiler/main/DriverMkDepend.hs @@ -62,15 +62,15 @@ doMkDependHS session srcs ; excl_mods <- readIORef v_Dep_exclude_mods ; r <- GHC.depanal session excl_mods True {- Allow dup roots -} ; case r of - Left e -> do printErrorsAndWarnings e; exitWith (ExitFailure 1) - Right mod_summaries -> do { + Nothing -> exitWith (ExitFailure 1) + Just mod_summaries -> do { -- Sort into dependency order -- There should be no cycles let sorted = GHC.topSortModuleGraph False mod_summaries Nothing -- Print out the dependencies if wanted - ; debugTraceMsg dflags 2 (showSDoc (text "Module dependencies" $$ ppr sorted)) + ; debugTraceMsg dflags 2 (text "Module dependencies" $$ ppr sorted) -- Prcess them one by one, dumping results into makefile -- and complaining about cycles