diff options
author | Raymond Hettinger <python@rcn.com> | 2008-01-30 02:55:10 +0000 |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2008-01-30 02:55:10 +0000 |
commit | 1fa6f10ebe6dbc89b5c8ebc9dd69dfc4fb72de5b (patch) | |
tree | b6243ad9e9d25d5ff81b136d20dea51317eacd14 /Lib/ctypes/util.py | |
parent | af56861fd55c0daa5e6be0883772444cd4eb2c8b (diff) | |
download | cpython-1fa6f10ebe6dbc89b5c8ebc9dd69dfc4fb72de5b.tar.gz |
Convert some custom sort comparison functions to equivalent key functions.
Diffstat (limited to 'Lib/ctypes/util.py')
-rw-r--r-- | Lib/ctypes/util.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/ctypes/util.py b/Lib/ctypes/util.py index 733a99c4d7..3e6ae0104b 100644 --- a/Lib/ctypes/util.py +++ b/Lib/ctypes/util.py @@ -123,7 +123,7 @@ elif os.name == "posix": res = re.findall(expr, data) if not res: return _get_soname(_findLib_gcc(name)) - res.sort(cmp= lambda x,y: cmp(_num_version(x), _num_version(y))) + res.sort(key=_num_version) return res[-1] else: |