Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Trac #20312: parent of argument lost with Functions
Some Python objects as function arguments lose their parent, i.e. the code in the specific function can no longer access it because the object was coerced into SR. This can result in violation of the rule that function input and output should be of the same type. {{{ sage: S.<y> = PolynomialRing(RR) sage: ex = sin(asin(y)); ex y sage: type(ex) <type 'sage.symbolic.expression.Expression'> sage: ex.is_symbol() True }}} The specific function (here sin) code cannot remedy this because there the damage is already done. The problem is in `symbolic/function.pyx:BuiltinFunction.__call__` where the parent of function arguments is lost. See also #18832 and maybe #17790. URL: http://trac.sagemath.org/20312 Reported by: rws Ticket author(s): Ralf Stephan Reviewer(s): Volker Braun
- Loading branch information