Hello,

On Tue, Jul 27, 2010 at 12:30 PM, Simon King <simon.k...@nuigalway.ie> wrote:
> So, the fact that RingElement uses the category framework means that
> both the code *and* the documentation are hidden behind layers of
> abstraction, to the extent that they can actually not be accessed *at
> all*, unless one untars the spkg? That's pretty nasty and, I might
> add, anti-pedagogical.

This is not that case -- please stop using the "category framework" as
a scapegoat.  Suppose you have the following code.

cdef class Foo:
    def __pow__(self, n, z):
        return 4
f = Foo()

Then,  f.__pow__?? will fail since f.__pow__.__doc__ is a special
read-only attribute and does not contain the file information needed
by the introspection system to find the source code.

An enhancement to the introspection code would be to try to look at
"foo.__class__.__module__" in order to find the file where the source
code is.  Note that this won't work in general, but could work with
Sage code.

Again, this has nothing to do with the category code.

--Mike

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

Reply via email to