Skip to content

Add types and functions in types.py that are new in 3.7#3066

Merged
JelleZijlstra merged 4 commits intopython:masterfrom
CraftSpider:master
Jun 19, 2019
Merged

Add types and functions in types.py that are new in 3.7#3066
JelleZijlstra merged 4 commits intopython:masterfrom
CraftSpider:master

Conversation

@CraftSpider
Copy link
Contributor

As declared in the title, this adds the types and the single new function that were added to the types.py module in Python 3.7.
Closes #3064

@CraftSpider
Copy link
Contributor Author

I also noticed that at least one of the new types does define its own __lt__, __gt__, etc, and I wasn't sure whether to include those.

@srittau
Copy link
Collaborator

srittau commented Jun 17, 2019

Generally, dunder methods should be included, except when they are already defined the same way in the superclass hierarchy.

A few dunder methods like __str__ and __repr__ are defined on object.

@CraftSpider
Copy link
Contributor Author

Went and actually examined the CPython implementation for 3.7, added the implemented comparison operators.

@JelleZijlstra JelleZijlstra merged commit 58221cf into python:master Jun 19, 2019
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.

No stubs for wrapper/descriptor types

3 participants