Implement tail-call analysis for 4.01