blob: a582b10e20729bab7862393a27445bc9683c4383 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
{-# LANGUAGE GADTs #-}
module Main where
infix 5 :*:
data T a where
(:*:) :: Int -> a -> T a
(:+:) :: Char -> T a -> T a
deriving( Show )
-- The Show should print (:*:) infix, but (:+:) prefix,
-- since it lacks a fixity declaration
main = print ('x' :+: (3 :*: True))
|