-
Notifications
You must be signed in to change notification settings - Fork 4.5k
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
ObjectFactory<T>
delegate should be covariant
#101829
Comments
Tagging subscribers to this area: @dotnet/area-extensions-dependencyinjection |
runtime/src/libraries/Microsoft.Extensions.DependencyInjection.Abstractions/src/ObjectFactoryT.cs Line 15 in ee93104
|
Would it be possible to use |
That would need to be an entirely different delegate and an entirely different set of APIs that take that delegate... just changing the delegate itself would be a binary breaking change. Feel free to open a separate issue with such a proposal. |
Opened #101889 |
Current workaround is to use the non-generic ObjectFactory and cast but that shouldn't be necessary.
API Proposal
The text was updated successfully, but these errors were encountered: