On Mon, Nov 30, 2009 at 5:19 PM, Simon King <simon.k...@nuigalway.ie> wrote:
> Hi!
>
> At #6854 (ready for review, I think), I implemented introspection and
> tab completion for elements of Infinite Polynomial Rings. This became
> necessary since they have a __getattr__ method that allows to use
> methods of the underlying *finite* polynomial (e.g., _latex_) in an
> easy way, to the expence of leaving these "pseudo-inherited" methods
> invisible for introspection and tab completion.
>
> It is clear how to doc test introspection: use dir() on an instance of
> the class.
>
> But how to doc test tab completion? Is there a better way than to call
> the relevant underscore method (here: _getAttributeNames) directly?
>

I would call the code in the Sage notebook that is used to *implement*
tab completion.

sage: import sagenb.misc.support as s
sage: n = 949292
sage: s.completions('n.f',globals(),system='python')
['n.factor', 'n.factorial', 'n.floor']

 -- William

-- 
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel-unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org

Reply via email to