From ce1a6681c0992a4cb85580d36e465b78723e895d Mon Sep 17 00:00:00 2001 From: Jaro Date: Fri, 21 Apr 2023 17:05:57 +0200 Subject: [PATCH] Use concise expression for readFromFile. --- test/Data/Text/ParagraphLayout/PrettyShow/Golden.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/Data/Text/ParagraphLayout/PrettyShow/Golden.hs b/test/Data/Text/ParagraphLayout/PrettyShow/Golden.hs index a36adde..a9ff282 100644 --- a/test/Data/Text/ParagraphLayout/PrettyShow/Golden.hs +++ b/test/Data/Text/ParagraphLayout/PrettyShow/Golden.hs @@ -25,7 +25,7 @@ goldenTest goldenDir unwrap wrap innerOutput name = Golden { output = wrap innerOutput , encodePretty = show . unwrap , writeToFile = \ path -> writeFile path . prettyShow - , readFromFile = \ path -> readFile path >>= return . wrap . read + , readFromFile = \ path -> wrap . read <$> readFile path , goldenFile = goldenPath goldenDir name , actualFile = Just (actualPath goldenDir name) , failFirstTime = True -- 2.30.2