From f27ae116a3f21880f7810bb625d4c6c7c5f4e165 Mon Sep 17 00:00:00 2001 From: Simon Jakobi Date: Tue, 21 Jan 2020 01:44:01 +0100 Subject: [PATCH] Naively use valid in filter --- prettyprinter/test/Testsuite/Main.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/prettyprinter/test/Testsuite/Main.hs b/prettyprinter/test/Testsuite/Main.hs index 6f069708..4012d3a7 100644 --- a/prettyprinter/test/Testsuite/Main.hs +++ b/prettyprinter/test/Testsuite/Main.hs @@ -114,7 +114,7 @@ fusionDoesNotChangeRendering depth instance Arbitrary ann => Arbitrary (Doc ann) where arbitrary = document - shrink doc = case doc of + shrink doc = filter valid $ case doc of Fail -> [Empty] Empty -> [] Char c -> Empty : map Char (filter (/= '\n') (shrink c))