#11791: Introspection for interactively defined classes with metaclass
-----------------------------------------------------------------+----------
Reporter: SimonKing |
Owner: jason
Type: enhancement |
Status: needs_review
Priority: major |
Milestone: sage-5.0
Component: misc |
Resolution:
Keywords: introspection, cython, dynamic metaclass | Work
issues:
Report Upstream: N/A |
Reviewers:
Authors: Simon King | Merged
in:
Dependencies: #11298, #11768, #11734, #11115, #10620, #9107 |
Stopgaps:
-----------------------------------------------------------------+----------
Changes (by SimonKing):
* dependencies: #11298, #11768, #11734, #11115, #10620 => #11298,
#11768, #11734, #11115, #10620, #9107
Comment:
In some cases, sage_getfile would still not get the correct file name for
interactively defined classes. Hence, the following would not work, even
with #9107 applied:
{{{
age: cython_code = [
... "from sage.structure.unique_representation import
UniqueRepresentation",
... "class A1(UniqueRepresentation):",
... " class B1(UniqueRepresentation):",
... " class C1: pass",
... " class B2:",
... " class C2: pass"]
sage: import os
sage: cython(os.linesep.join(cython_code))
sage: A1.B1.C1??
}}}
I fixed the problem and turn it into a new doctest. However, that makes
#9107 a new dependency (for making the test work).
I also used that occasion to use the new :trac: directive, and was a bit
more careful by using os.extsep instead of '.' and so on.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11791#comment:6>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.