#11935: Make parent/element classes independent of base rings
-----------------------------------------------------------------+----------
       Reporter:  SimonKing                                      |         
Owner:              
           Type:  enhancement                                    |        
Status:  needs_review
       Priority:  major                                          |     
Milestone:  sage-5.0    
      Component:  categories                                     |    
Resolution:              
       Keywords:  parent class, element class, category          |   Work 
issues:              
Report Upstream:  N/A                                            |     
Reviewers:              
        Authors:  Simon King                                     |     Merged 
in:              
   Dependencies:  #9138, #11900, #11943, #12875, #12876, #12877  |      
Stopgaps:              
-----------------------------------------------------------------+----------

Comment (by nthiery):

 Speaking of weak cache: currently trac11935_share_on_base_category.patch
 uses strong caching. Weak caching might be preferable.

 Another thing is that this patch could be quite more concise if we had
 another feature in cached functions: namely that we could specify that
 certain arguments should be ignored in the cache lookup; or more generally
 that we could specify a function that would produce the key to be used in
 the cache lookup. Something like:
 {{{
      def key(x, l, option=1): return x, tuple(l)

      @cached_function(key=key)
      def foo(x, l, option=1):
          return (x, l, option)

      sage: foo(1, [1,2], 3) is foo(1, (1,2), 2)
      True
 }}}
 Better syntax welcome!

 Cheers,
                                                      Nicolas

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

Reply via email to