#14058: Weakly reference binary operation codomains
-------------------------------------+-------------------------------------
       Reporter:  robertwb           |        Owner:  rlm
           Type:  enhancement        |       Status:  needs_review
       Priority:  major              |    Milestone:  sage-6.4
      Component:  memleak            |   Resolution:
       Keywords:                     |    Merged in:
        Authors:  Robert Bradshaw,   |    Reviewers:  Simon King
  Nils Bruin                         |  Work issues:
Report Upstream:  N/A                |       Commit:
         Branch:                     |  9793dbc9bc64bfdce43ff1e626453816c302696d
  u/SimonKing/weakly_reference_binary_operation_codomains|     Stopgaps:
   Dependencies:  #12313             |
-------------------------------------+-------------------------------------

Comment (by SimonKing):

 Sometimes, the following test in sage/categories/fields.py has failed:
 {{{
             sage: import gc
             sage: _ = gc.collect()
             sage: n = len([X for X in gc.get_objects() if isinstance(X,
 sage.rings.finite_rings.integer_mod_ring.IntegerModRing_generic)])
             sage: for i in prime_range(100):
             ....:     R = ZZ.quotient(i)
             ....:     t = R in Fields()
             sage: _ = gc.collect()
             sage: len([X for X in gc.get_objects() if isinstance(X,
 sage.rings.finite_rings.integer_mod_ring.IntegerModRing_generic)]) - n
             1
 }}}
 The reason for the failure: Sometimes the last line gave 0, not 1. It is
 not totally clear to me why the different results occurred. But in fact 0
 is better than 1 here (one additional ring got collected). So, I hope my
 change is OK.

--
Ticket URL: <http://trac.sagemath.org/ticket/14058#comment:45>
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