Use </> rather than ++ "/"
authorIan Lynagh <igloo@earth.li>
Thu, 25 Mar 2010 13:32:37 +0000 (13:32 +0000)
committerIan Lynagh <igloo@earth.li>
Thu, 25 Mar 2010 13:32:37 +0000 (13:32 +0000)
This stops us generating paths like
    c:\foo\/ghc460_0/ghc460_0.o
which windres doesn't understand.

compiler/main/SysTools.lhs

index 5a0c45b..ac1941d 100644 (file)
@@ -480,7 +480,7 @@ newTempName :: DynFlags -> Suffix -> IO FilePath
 newTempName dflags extn
   = do d <- getTempDir dflags
        x <- getProcessID
-       findTempName (d ++ "/ghc" ++ show x ++ "_") 0
+       findTempName (d </> "ghc" ++ show x ++ "_") 0
   where
     findTempName :: FilePath -> Integer -> IO FilePath
     findTempName prefix x