* geometry.asy: fix casting bug leading to stack overflow