diff options
Diffstat (limited to 'testsuite/tests/rename/should_compile/T3901.hs')
-rw-r--r-- | testsuite/tests/rename/should_compile/T3901.hs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/testsuite/tests/rename/should_compile/T3901.hs b/testsuite/tests/rename/should_compile/T3901.hs new file mode 100644 index 0000000000..71944a4142 --- /dev/null +++ b/testsuite/tests/rename/should_compile/T3901.hs @@ -0,0 +1,16 @@ +{-# LANGUAGE RecordWildCards, TransformListComp, NamedFieldPuns #-} + +module T3901 where + +import GHC.Exts (groupWith) + +data Rec = Rec {a :: Int} deriving (Show) + +recs1 = [a | Rec {a=a} <- [Rec 1], then group by a using groupWith] + +recs2 = [a | Rec {a} <- [Rec 1], then group by a using groupWith] + +recs3 = [a | Rec {..} <- [Rec 1], then group by a using groupWith] + +recs4 :: [[Int]] +recs4 = [a | Rec {..} <- [Rec 1], then group by a using groupWith] |