Am 2014-07-28 um 17:47 schrieb Volker Braun:
> On Monday, July 28, 2014 11:42:05 AM UTC-4, William wrote:
> Specifically for dictionaries we also have the displayhook sorting by key:
> 
> sage: d = {'a':23, 'b':34, 'au':56, 'bbf':234, 'aaa':234}
> sage: str(d)    # dict uses internal order 
> "{'a': 23, 'bbf': 234, 'aaa': 234, 'b': 34, 'au': 56}"
> sage: d           # displayhook sorts alphabetically
> {'a': 23, 'aaa': 234, 'au': 56, 'b': 34, 'bbf': 234}

Does this mean it is guaranteed that in doctests dicts are always shown
with their keys sorted?

Daniel

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to