[Zope-dev] ZTK 2.0: Deprecate zope.sequencesort
Tres Seaver
tseaver at palladion.com
Thu Feb 28 16:32:26 UTC 2013
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 02/28/2013 08:43 AM, Stephan Richter wrote:
> Hi everyone,
>
> I would like to deprecate zope.sequencesort in ZTK 2.0, since it
> cannot properly ported to Python 3, since it depends heavily on the
> cmp() way of sorting. I am also not a user of the package and I only
> tried to port the package for completeness sake.
>
> Thoughts?
I'm generally in favor of shrinking the ZTK, but just for discussion's
sake: emulating 'cmp' for objects which have rich comparison semantics
isn't that difficult::
def _faux_cmp(lhs, rhs):
return int(rhs < lhs) - int(lhs < rhs)
Tres.
- --
===================================================================
Tres Seaver +1 540-429-0999 tseaver at palladion.com
Palladion Software "Excellence by Design" http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with undefined - http://www.enigmail.net/
iEYEARECAAYFAlEvhpoACgkQ+gerLs4ltQ54KACggufMQUYdhD1Y9pefcP0qvAEE
oEMAoLwcOL9/gGtdsIUJ0YlMme85WGhZ
=ayRa
-----END PGP SIGNATURE-----
More information about the Zope-Dev
mailing list