Fix recursive calls tracked in wrong order

Fixes #13