-
Notifications
You must be signed in to change notification settings - Fork 37
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
Setter for collection type #61
Comments
Are you looking to be able to create more specific classes of the collection so you can type hint on specific types? Example: Or are you just looking for type inference on type of items the collection uses at construction? Example: |
@danielgsims the first option :) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
At work we use this collections to improve type hinting. Example:
But we always need to declare the collection type, which is strange because we have a class for the collection and it should know his type.
As result we ended up with this abstract class:
Wich allow us to do this:
I'm wondering if it makes sense to you, and if so, there is a way to add this feature into this project.
The text was updated successfully, but these errors were encountered: