This repository has been archived by the owner on Nov 8, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 18
New rule proposal: Propagate cancellation tokens #37
Labels
Comments
👍 |
I will implement this analysis. |
I think that this analysis should be also triggered if |
@tmaczynski Yes, that's correct. |
I'm hesitating if local fields of type CancellationToken should be considered in this diagnostic or not (current description suggests that they should not), any thought on that? Also, I think that all CancellationToken parameters, local variables (and possibly, fields) should be suggested by a codefix provider, not only the "best" (innermost) one. |
@tmaczynski I'm not sure for fields. I could see it going either way. |
@tmaczynski Oh, maybe just treat |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
This diagnostic would be reported when
CancellationToken.None
is explicitly provided in a call, but another cancellation token is available in the current context (see #36 and #32 for comments describing the current context).The code fix for this would replace the use of
CancellationToken.None
with the "best" cancellation token as described in the code fix for #36.The text was updated successfully, but these errors were encountered: