#17138: LatticePoset: complements() is broken
-------------------------------------+-------------------------------------
Reporter: jmantysalo | Owner:
Type: defect | Status: positive_review
Priority: major | Milestone: sage-6.4
Component: combinatorics | Resolution:
Keywords: | Merged in:
Authors: Jori Mäntysalo | Reviewers: Nathann Cohen
Report Upstream: N/A | Work issues:
Branch: | Commit:
public/latticeposet__complements___is_broken|
cf4f72988a9910e9e64bbef4653524b59af5c67b
Dependencies: | Stopgaps:
-------------------------------------+-------------------------------------
Comment (by vbraun):
The order in `sorted(['a', 42])` is random (depends on memory location).
`sorted(['a', '42'])` is not. Dictionaries are sorted by key in the
displayhook, so if you don't mix strings and ints as keys then they are
always printed he same.
Possible solutions
* don't mix string and int as keys
* Doctest equality of dicts `L.complements() == {...}` instead of the dict
repr
--
Ticket URL: <http://trac.sagemath.org/ticket/17138#comment:22>
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.