diff options
Diffstat (limited to 'Build/EvilSplicer.hs')
-rw-r--r-- | Build/EvilSplicer.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Build/EvilSplicer.hs b/Build/EvilSplicer.hs index 66032bad7..6fef646ae 100644 --- a/Build/EvilSplicer.hs +++ b/Build/EvilSplicer.hs @@ -197,14 +197,14 @@ applySplices :: FilePath -> Maybe String -> [Splice] -> IO () applySplices destdir imports splices@(first:_) = do let f = splicedFile first let dest = (destdir </> f) - putStrLn $ "splicing " ++ f lls <- map (++ "\n") . lines <$> readFileStrict f createDirectoryIfMissing True (parentDir dest) let newcontent = concat $ addimports $ expanddeclarations declarationsplices $ expandexpressions lls expressionsplices oldcontent <- catchMaybeIO $ readFileStrict dest - when (oldcontent /= Just newcontent) $ + when (oldcontent /= Just newcontent) $ do + putStrLn $ "splicing " ++ f writeFile dest newcontent where (expressionsplices, declarationsplices) = |