Fix confusing use of GetService extensions with different behavior#46030
Merged
sharwell merged 3 commits intodotnet:masterfrom Jul 16, 2020
Merged
Fix confusing use of GetService extensions with different behavior#46030sharwell merged 3 commits intodotnet:masterfrom
sharwell merged 3 commits intodotnet:masterfrom
Conversation
davidwengier
approved these changes
Jul 16, 2020
jasonmalinowski
approved these changes
Jul 16, 2020
Member
jasonmalinowski
left a comment
There was a problem hiding this comment.
Thank you for fixing this! Question is not blocking, since cleaning this up first is clearly necessary!
| public static TInterfaceType GetService<TInterfaceType, TServiceType>(this IServiceProvider sp) | ||
| where TInterfaceType : class | ||
| where TServiceType : class | ||
| /// <inheritdoc cref="Shell.ServiceExtensions.GetService{TService, TInterface}(IServiceProvider, bool)"/> |
Member
There was a problem hiding this comment.
Any reason we're not just using the one that comes from the Shell binaries in the first place? Will this also inherit a documentation that won't apply for whatever that bool parameter is?
Contributor
Author
There was a problem hiding this comment.
Any reason we're not just using the one that comes from the Shell binaries in the first place?
It uses ThreadHelper.JoinableTaskFactory. I'm not sure we initialize that property in test scenarios.
Will this also inherit a documentation that won't apply for whatever that bool parameter is?
Not really, it just ignores it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Review commit-by-commit encouraged 😄