summaryrefslogtreecommitdiff
path: root/testsuite/tests/patsyn/should_compile/T8584-2.hs
blob: 379a8c872eb1fdfdb5c9a3eb9661043eaf77f70f (plain)
1
2
3
4
5
6
7
8
9
10
{-# OPTIONS_GHC -fno-warn-redundant-constraints #-}
{-# LANGUAGE PatternSynonyms #-}

module ShouldCompile where

pattern Single :: Show a => a -> [a]
pattern Single x = [x]

f :: (Show a) => [a] -> a
f (Single x) = x