
13 Jan
2008
13 Jan
'08
2:09 p.m.
Fernando Rodriguez writes:
What on Earth is ghc talking about? O:-) (overlapping paterns)
emptyBT = EmptyTree
depth emptyBT = 0 depth (NodeBT _ left right) = max (1 + depth left) (1 + depth right)
GHC is always right... Your first clause is GENERIC, the pattern is a variable, not a constant. Replace emptyBT by EmptyTree. Jerzy Karczmarczuk