From: simonmar Date: Mon, 30 Apr 2001 09:40:16 +0000 (+0000) Subject: [project @ 2001-04-30 09:40:16 by simonmar] X-Git-Tag: Approximately_9120_patches~2069 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=f855f3a88f9c90f661796e0b765639bc3001a292;p=ghc-hetmet.git [project @ 2001-04-30 09:40:16 by simonmar] Reverse the directory list when building the home package directory cache, so that earlier entries override later ones. --- diff --git a/ghc/compiler/main/Finder.lhs b/ghc/compiler/main/Finder.lhs index c9ce6a1..f805654 100644 --- a/ghc/compiler/main/Finder.lhs +++ b/ghc/compiler/main/Finder.lhs @@ -84,7 +84,7 @@ maybeHomeModule mod_name = do contents <- softGetDirectoryContents path let clean_contents = filter isUsefulFile contents return (addListToFM fm (zip clean_contents (repeat path))) - home_map <- foldM extendFM emptyFM home_imports + home_map <- foldM extendFM emptyFM (reverse home_imports) writeIORef v_HomeDirCache (Just home_map) return home_map