You can use `evaluateObjectExpression` and avoid the cast.