Mercurial > babel > old > babel-test
comparison babel/util.py @ 369:c2ae38340540 stable-0.9.x
Ported [388:405/trunk] to 0.9.x branch.
author | cmlenz |
---|---|
date | Fri, 27 Jun 2008 15:22:12 +0000 |
parents | faf0ead3a132 |
children | b29ff192b610 |
comparison
equal
deleted
inserted
replaced
368:7647773d3831 | 369:c2ae38340540 |
---|---|
27 missing = object() | 27 missing = object() |
28 | 28 |
29 __all__ = ['distinct', 'pathmatch', 'relpath', 'wraptext', 'odict', 'UTC', | 29 __all__ = ['distinct', 'pathmatch', 'relpath', 'wraptext', 'odict', 'UTC', |
30 'LOCALTZ'] | 30 'LOCALTZ'] |
31 __docformat__ = 'restructuredtext en' | 31 __docformat__ = 'restructuredtext en' |
32 | |
32 | 33 |
33 def distinct(iterable): | 34 def distinct(iterable): |
34 """Yield all items in an iterable collection that are distinct. | 35 """Yield all items in an iterable collection that are distinct. |
35 | 36 |
36 Unlike when using sets for a similar effect, the original ordering of the | 37 Unlike when using sets for a similar effect, the original ordering of the |