Hello, complete noob to Haskell here with probably an even noobier question. I'm trying to get ghci output working and am stuck on instance declarations. How could I declare an instance for "(Show (Stack -> Stack))" given:
data Cmd = LD Int
| ADD
| MULT
| DUP
deriving Show
type Prog = [Cmd]
type Stack = [Int]
type D = Stack -> Stack
I've been trying to create a declaration like:
instance Show D where show = Stack
but all my attempts have resulted in illegal instance declarations. Any help and/or references much appreciated!