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 #805

Closed
wants to merge 12 commits into from

Conversation

AmadeusW
Copy link

@AmadeusW AmadeusW commented Jul 4, 2016

Fixes #734
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

giggio and others added 12 commits April 3, 2016 03:53
This had to be done manually, as the other CodeAnalysis
packages depend on version =1.0.0 of
Microsoft.CodeAnalysis.Analyzers, so, if using VS to do
this, it will auto upgrade all Microsoft.CodeAnalysis.*
packages to 1.1.0 as well, which will keep the analyzer
from working on VS 2015 RTM, only working on Update 1.
Allow now build from tags.
Deploy now from tags not from the release branch anymore.
For patches, now deploy to myget
any branch that looks like a version number, like:
v1.0.x
v3.9.x
Always ending with an `x`.
Fix 'BUG: CC0052 (Make readonly) should not be applied to complex value types code-cracker#775'
Adds Design Warning CC0122 when
`System.Threading.Tasks.Task<TResult>.Result` is used in `async` method.
The code fix provider replaces `.Result` with `async `
@coveralls
Copy link

Coverage Status

Coverage increased (+0.03%) to 90.925% when pulling d0cd1fd on AmadeusW:0122 into 38b630a on code-cracker:vnext.

@giggio giggio self-assigned this Aug 7, 2016
@giggio
Copy link
Member

giggio commented Aug 7, 2016

@AmadeusW You have some problem with your commits, you probably merged from CodeCracker's master into your branch, or something else. You can see that on the Commit tab here at github, it shows 12 commits and 35 changed files.
Also, you should change the pull to branch master, not vnext.

@giggio
Copy link
Member

giggio commented Aug 7, 2016

Taking a look at the commits, what you should do is:

  • Update your master branch, according to CodeCracker's master branch git checkout master, then git pull https://github.com/code-cracker/code-cracker.git master.
  • Create a new branch git checkout -b newbranch
  • Cherry pick your commits into it git cherry-pick 91e3e6d4fa05ea002c1844ab2665a00d0f8ca18c and git cherry-pick 23ebf1b89136cee55fd48caa48c0949dce0cd848.

Then open the PR with this branch, and close this one.

@AmadeusW
Copy link
Author

Thanks @giggio, I'm closing this in favor of #820

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants