Skip to content
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

CC0122 Replace Task.Result with await Task #820

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AmadeusW
Copy link

Fixes #734
Supersedes #805
CC0122 Replace Task.Result with await Task

Adds Design Warning CC0122 when System.Threading.Tasks.Task<TResult>.Result is used in async method.
The code fix provider replaces .Result with async

Screenshot of a non trivial case:
cc0122

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.07%) to 91.552% when pulling 9fea23d on AmadeusW:resultInAsync into 794c05a on code-cracker:master.

@giggio giggio self-assigned this Aug 14, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Replace Task.Result with await Task
3 participants