blob: 6f35e3c79291923b0b98810a219837d4fdf79453 (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE ViewPatterns #-}
module PatternPanic where
pattern TestPat :: (Int, Int)
pattern TestPat <- (isSameRef -> True, 0)
isSameRef :: Int -> Bool
isSameRef e | 0 <- e = True
isSameRef _ = False
|