Can you write a docstring explaining this?  I think I've seen this idea of popping to a particular level, and now that I see it here, I'm wondering why I didn't need it before (though of course I did need it before!)