What about John Hughes' `foldtree` am I misunderstanding?
A proper definition should consist of a pair of mutually recursive functions, one for folding trees and one for folding forests (lists of trees):
foldtree :: (a -> c -> b) -> (b -> c -> c) -> c -> Treeof a -> b
foldtree f g a (Node label subtrees) = f label (foldforest f g a subtrees)
foldforest :: (a -> c -> b) -> (b -> c -> c) -> c -> Listof (Treeof a) -> c
foldforest f g a (Cons subtree rest) = g (foldtree f g a subtree) (foldforest f g a rest)
foldforest f g a Nil = a
I think the author has mistakenly combined two different (but closely related) functions together. I suspect what the author wrote is not really Haskell but more of a Haskell-like pseudocode, so the code was just used to present the algorithm in an informal way.
Note that the paper seems to suggest it's Miranda, a predecessor of Haskell, but I can't confirm if this is legal Miranda code either.