blob: 00b3f724de9ce6fe0a0de84a722cdbf01aef12cb (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
{-# LANGUAGE DatatypeContexts, ExistentialQuantification #-}
-- Tests the "stupid theta" in pattern-matching
-- when there's an existential as well
module ShouldCompile where
data (Show a) => Obs a = forall b. LiftObs a b
f :: Show a => Obs a -> String
f (LiftObs _ _) = "yes"
|