#14912: UniqueRepresentation tutorial could use more love
-------------------------------------+-------------------------------------
       Reporter:  darij              |        Owner:
           Type:  defect             |       Status:  positive_review
       Priority:  major              |    Milestone:  sage-6.1
      Component:  documentation      |   Resolution:
       Keywords:  documentation,     |    Merged in:
  structure                          |    Reviewers:  Darij Grinberg,
        Authors:  Simon King         |  Travis Scrimshaw
Report Upstream:  N/A                |  Work issues:
         Branch:                     |       Commit:
   Dependencies:  #14888             |     Stopgaps:
-------------------------------------+-------------------------------------

Comment (by SimonKing):

 Replying to [comment:68 tscrim]:
 > There's this line in `unique_representation.py`:
 > {{{
 >     @weak_cached_function # automatically a staticmethod
 >     def __classcall__(cls, *args, **options):
 > }}}
 > so apparently it's not a contradiction. Although I don't specifically
 know why it's used (in `src/sage/groups/perm_gps/permgroup_named.py`)
 instead of a `@staticmethod`.

 There is some argument pre-processing: `kwds['domain']` might change. And
 this ''changed'' argument is used as a cache key when calling
 `super(PermutationGroup_unique, cls).__classcall__(cls, *args, **kwds)`.
 Apparently the author of this `__classcall__` found it desirable that the
 instance is pulled from the cache when the original value of
 `kwds['domain']` is provided next time, ''without'' losing time by the
 preprocessing.

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