Can one express catamorphism through Data.Function.fix?
问题 I have this lovely fixana function here that performs about 5 times faster than her sister ana . (i have a criterion report to back me on this) ana alg = Fix . fmap (ana alg) . alg fixana alg = fix $ \f -> Fix . fmap f . alg Can I express their cousin cata in the same fashion? cata f = f . fmap (cata f) . unFix It seems to me that I cannot, but I have been humbled by my S.O. fellows quite a few times in the past. 回答1: Actually, this has nothing to do with catamorphisms. Whenever a function is