How can I list all calls to the Task- or Task <T> -returning method that have no pending call in the solution?
How can I list all method calls Task
- or Task<T>
-returning - that have no call await
in the solution?
I searched a few things on Google but nothing came up.
For example:
public Task<bool> DoWork()
{
return Task.FromResult(true); // would be listed, even though it "correct"
}
public async Task DoMoreWork()
{
await DoWork(); // would not be listed
DoWork(); // would be listed
DoWork(); // would be listed a second time in this same method
}
public void DoEvenMoreWork()
{
DoWork(); // would be listed
}
We are using .NET Framework 4.5.
+1
source to share
No one has answered this question yet
See similar questions:
or similar: