fixed cast-and-eval bug