Fix for analytic functions - sync with not-AST version