You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Looking at the code in sage/structure/mutability.pyx, one notices some things that should be changed:
Update the methods in Mutability: The corresponding methods in sage/structure/sequence.py seem to work nicely. E.g. there self._is_immutable = 1 (in set_immutable) was changed to self._is_immutable = True or self._is_immutable got a return and a try-except (in is_immutable))
Add a doctest in require_mutable and require_immutable that uses the class Mutability.
Add doctests to set_immutable and to is_immutable that really test the code (and note just test the code in sage/structure/sequence.py.
Add doctests to all functions.
Maybe: combine _require_mutable and _require_mutable_cdef with cpdef.
Looking at the code in
sage/structure/mutability.pyx
, one notices some things that should be changed:Update the methods in
Mutability
: The corresponding methods insage/structure/sequence.py
seem to work nicely. E.g. thereself._is_immutable = 1
(inset_immutable
) was changed toself._is_immutable = True
orself._is_immutable
got areturn
and a try-except (inis_immutable
))Add a doctest in
require_mutable
andrequire_immutable
that uses the classMutability
.Add doctests to
set_immutable
and tois_immutable
that really test the code (and note just test the code insage/structure/sequence.py
.Add doctests to all functions.
Maybe: combine
_require_mutable
and_require_mutable_cdef
withcpdef
.See also the discussion "Mutability" on sage-devel https://groups.google.com/forum/#!topic/sage-devel/dnXSgh56Boo
Component: misc
Keywords: mutability doctests
Issue created by migration from https://trac.sagemath.org/ticket/15264
The text was updated successfully, but these errors were encountered: