Debugging head-corner algorithm.