fixed tail-recursion in .ply reader