Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

__cmp__ removal not in What's New #48622

Closed
terryjreedy opened this issue Nov 20, 2008 · 2 comments
Closed

__cmp__ removal not in What's New #48622

terryjreedy opened this issue Nov 20, 2008 · 2 comments
Assignees
Labels
docs Documentation in the Doc dir

Comments

@terryjreedy
Copy link
Member

BPO 4372
Nosy @birkenfeld, @terryjreedy, @vstinner

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = 'https://github.com/birkenfeld'
closed_at = <Date 2008-11-21.14:12:19.747>
created_at = <Date 2008-11-20.22:48:47.109>
labels = ['docs']
title = "__cmp__ removal not in What's New"
updated_at = <Date 2008-11-21.14:16:15.904>
user = 'https://github.com/terryjreedy'

bugs.python.org fields:

activity = <Date 2008-11-21.14:16:15.904>
actor = 'vstinner'
assignee = 'georg.brandl'
closed = True
closed_date = <Date 2008-11-21.14:12:19.747>
closer = 'vstinner'
components = ['Documentation']
creation = <Date 2008-11-20.22:48:47.109>
creator = 'terry.reedy'
dependencies = []
files = []
hgrepos = []
issue_num = 4372
keywords = []
message_count = 2.0
messages = ['76147', '76183']
nosy_count = 3.0
nosy_names = ['georg.brandl', 'terry.reedy', 'vstinner']
pr_nums = []
priority = 'normal'
resolution = 'duplicate'
stage = None
status = 'closed'
superseder = None
type = None
url = 'https://bugs.python.org/issue4372'
versions = ['Python 3.0']

@terryjreedy
Copy link
Member Author

What's New in Python 3.0/Common stumbling blocks
has this "builtin.sorted() and list.sort() no longer accept the cmp
argument providing a comparison function. Use the key argument instead."

Please add "The __cmp__ special method is no longer used for
comparisons. Use __lt__ for sorting, __eq__ with __hash__, and other
rich comparisons as needed."

People are already stumbling on this.

@terryjreedy terryjreedy added the docs Documentation in the Doc dir label Nov 20, 2008
@vstinner
Copy link
Member

Duplicate issue: see bpo-2306. Anyway, an you write a patch?

@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir
Projects
None yet
Development

No branches or pull requests

3 participants