#14711: Memleak when creating QuadraticField
-------------------------------------------------+-------------------------
       Reporter:  jpflori                        |        Owner:
           Type:  defect                         |  davidloeffler
       Priority:  critical                       |       Status:  new
      Component:  number fields                  |    Milestone:  sage-5.12
       Keywords:  memleak, number field,         |   Resolution:
  QuadraticField                                 |    Merged in:
        Authors:                                 |    Reviewers:
Report Upstream:  N/A                            |  Work issues:
         Branch:                                 |       Commit:
   Dependencies:                                 |     Stopgaps:
-------------------------------------------------+-------------------------

Comment (by SimonKing):

 I really wonder why the quadratic number field is put into
 `CDF._convert_from_list`. Is it perhaps in `Parent.convert_map_from()`?

 Namely, if a look-up in `_convert_from_hash` fails, then not only the
 `_convert_from_hash` gets updated, but also `_convert_from_list`:
 {{{
         try:
             return self._convert_from_hash.get(S)
         except KeyError:
             mor = self.discover_convert_map_from(S)
             self._convert_from_list.append(mor)
             self._convert_from_hash.set(S, mor)
             return mor
 }}}

 But why would this be done? Note that `_coerce_from_list` is ''not''
 updated when calling `Parent.coerce_map_from()`!!! So, this looks like an
 oversight to me. I hope it is, because then we would not need to mess
 around with yet another weak reference game.

--
Ticket URL: <http://trac.sagemath.org/ticket/14711#comment:12>
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/groups/opt_out.

Reply via email to