Skip to content

bpo-44978: allow Argument Clinic to handle __complex__ special methods #27886

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

Merged
merged 2 commits into from
Aug 22, 2021

Conversation

mdickinson
Copy link
Member

@mdickinson mdickinson commented Aug 22, 2021

As far as I can tell, __complex__ should need no special handling by Argument Clinic, so it should be safe to remove it from the set of unsupported methods. (__int__ and __float__ are there because they make use of a special slot, but __complex__ has no slot.)

https://bugs.python.org/issue44978

@mdickinson
Copy link
Member Author

For the record, I successfully implemented complex.__complex__ using Argument Clinic with this change in place. I'll make a separate PR for that.

Copy link
Member

@corona10 corona10 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm :)

@mdickinson mdickinson merged commit c5c3fbe into python:main Aug 22, 2021
@mdickinson mdickinson deleted the fix/clinic-complex-is-not-special branch August 22, 2021 12:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants