Skip to content

Add an Array Protocol & improve static typing support#589

Open
nstarman wants to merge 8 commits intodata-apis:mainfrom
nstarman:protocol
Open

Add an Array Protocol & improve static typing support#589
nstarman wants to merge 8 commits intodata-apis:mainfrom
nstarman:protocol

Conversation

@nstarman
Copy link
Contributor

@nstarman nstarman commented Feb 5, 2023

Continuing from #584, I've done a quick refactor of the array (and dtype) objects to make them typing Protocols.
@rgommers, I agree that making Array generic wrt the dtype is good for a followup.

It's not perfect, but mypy doesn't complain a whole lot, so I think this is a good start. I'm happy to make refinements.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

RFC Request for comments. Feature requests and proposed changes. topic: Static Typing Static typing.

Projects

None yet

Development

Successfully merging this pull request may close these issues.