On 25-May-09, at 11:26 PM, Kwankyu wrote:
> > Is there any reason that the abstract class definitions should not be > imported, at least for convenience? Yes. The sage namespace is already huge; importing all these definitions would make it truly impenetrable. You really can't create an Element at toplevel under normal circumstances, it's abstract. > If they are not imported, then I > think it takes some time for a new user to find out the right path > (that is, 'sage.structure.element') when he tries to extend the base > abstract class for his personal use. It takes time to learn a complex system. You might find Python's introspection useful, for example: sage: x x sage: type(x) <class 'sage .rings.polynomial.polynomial_element_generic.Polynomial_rational_dense'> sage: x.__module__ 'sage.rings.polynomial.polynomial_element_generic' sage: x.__class__ <class 'sage .rings.polynomial.polynomial_element_generic.Polynomial_rational_dense'> sage: x.__class__.__base__ <class 'sage .rings.polynomial.polynomial_element_generic.Polynomial_generic_field'> sage: x.__class__.__bases__ (<class 'sage .rings .polynomial.polynomial_element_generic.Polynomial_generic_field'>,) Nick --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to sage-devel-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---