diff options
author | Pauli Virtanen <pav@iki.fi> | 2010-02-20 18:03:14 +0000 |
---|---|---|
committer | Pauli Virtanen <pav@iki.fi> | 2010-02-20 18:03:14 +0000 |
commit | 60387a80f67dd2589c5ad4178219e4873417e877 (patch) | |
tree | f1fb2c6c09d7c100601ba8e30726ba809267e738 /numpy/core/_internal.py | |
parent | 06fad78714e65de87536a591087d5cf8c6410bce (diff) | |
download | numpy-60387a80f67dd2589c5ad4178219e4873417e877.tar.gz |
3K: core: sort using the key= method
Diffstat (limited to 'numpy/core/_internal.py')
-rw-r--r-- | numpy/core/_internal.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/core/_internal.py b/numpy/core/_internal.py index 813e40eef..815b59071 100644 --- a/numpy/core/_internal.py +++ b/numpy/core/_internal.py @@ -34,7 +34,7 @@ def _makenames_list(adict): title = None allfields.append((fname, format, num, title)) # sort by offsets - allfields.sort(lambda x,y: cmp(x[2],y[2])) + allfields.sort(key=lambda x: x[2]) names = [x[0] for x in allfields] formats = [x[1] for x in allfields] offsets = [x[2] for x in allfields] |