In a term of affects on the body. I believe that anorexia is worse. For the most part most symptoms of obesity can be reversed after losing weight. Unless in extreme conditions You can reverse most if not all effects of obesity.
Anorexia will leave lasting effects on your body. Things that are irreversible. Heart problems/kidney problems/stomach ulcers/ all the number of things that can go wrong.
The two are quite incomparable but if you look at it as damage on the body You can see which is worse.