#19125: DeprecatedMethod wrapping is broken
-------------------------------------+-------------------------------------
       Reporter:  nbruin             |        Owner:
           Type:  PLEASE CHANGE      |       Status:  needs_review
       Priority:  blocker            |    Milestone:  sage-6.9
      Component:  misc               |   Resolution:
       Keywords:                     |    Merged in:
        Authors:                     |    Reviewers:
Report Upstream:  N/A                |  Work issues:
         Branch:                     |       Commit:
  u/nbruin/ticket/19125              |  7f6cffe7e38835212a508f6fcf4f617e43c4103b
   Dependencies:                     |     Stopgaps:
-------------------------------------+-------------------------------------

Comment (by vdelecroix):

 The fix should be doctested! You can adapt the current behavior of
 {{{#!python
 sage: from sage.misc.superseded import deprecated_function_alias
 sage: class A:
 ....:    def __init__(self, x):
 ....:        self.x = x
 ....:    def f(self, y):
 ....:        return self.x+y
 ....:    g = deprecated_function_alias(42, f)
 sage: a1 = A(1)
 sage: a2 = A(2)
 sage: a1.g(a2.g(0))
 doctest:...: DeprecationWarning: g is deprecated. Please use f instead.
 See http://trac.sagemath.org/42 for details.
 4
 sage: a1.f(a2.f(0))
 3
 }}}

--
Ticket URL: <http://trac.sagemath.org/ticket/19125#comment:3>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to