[commit: ghc] wip/nfs-locking: Don't need . (6d4720c)

git at git.haskell.org git at git.haskell.org
Fri Oct 27 00:17:44 UTC 2017


Repository : ssh://git@git.haskell.org/ghc

On branch  : wip/nfs-locking
Link       : http://ghc.haskell.org/trac/ghc/changeset/6d4720c1e65d2b4a6cc88152f4547915aebcce42/ghc

>---------------------------------------------------------------

commit 6d4720c1e65d2b4a6cc88152f4547915aebcce42
Author: Andrey Mokhov <andrey.mokhov at gmail.com>
Date:   Sat Dec 26 16:25:14 2015 +0000

    Don't need .


>---------------------------------------------------------------

6d4720c1e65d2b4a6cc88152f4547915aebcce42
 src/Oracles/Config.hs | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/src/Oracles/Config.hs b/src/Oracles/Config.hs
index 5a163a6..e8333b6 100644
--- a/src/Oracles/Config.hs
+++ b/src/Oracles/Config.hs
@@ -7,6 +7,9 @@ import qualified Data.HashMap.Strict as Map
 newtype ConfigKey = ConfigKey String
     deriving (Show, Typeable, Eq, Hashable, Binary, NFData)
 
+configFile :: FilePath
+configFile = configPath -/- "system.config"
+
 askConfig :: String -> Action String
 askConfig key = askConfigWithDefault key . putError
     $ "Cannot find key '" ++ key ++ "' in configuration files."
@@ -21,11 +24,7 @@ askConfigWithDefault key defaultAction = do
 -- Oracle for configuration files
 configOracle :: Rules ()
 configOracle = do
-    let configFile = configPath -/- "system.config"
     cfg <- newCache $ \() -> do
-        unlessM (doesFileExist $ configFile <.> "in") $
-            putError $ "\nConfiguration file '" ++ (configFile <.> "in")
-                     ++ "' is missing; unwilling to proceed."
         need [configFile]
         putOracle $ "Reading " ++ configFile ++ "..."
         liftIO $ readConfigFile configFile



More information about the ghc-commits mailing list