An async method without await still creates a state machine.
That means overhead without benefit.
public async Task<int> CalculateAsync()
{
return 42;
}
Why this matters:
-
Extra allocations
-
Confusing stack traces
-
No real async benefit
Better:
public Task<int> CalculateAsync()
{
return Task.FromResult(42);
}
Cause → Effect
-
Unnecessary
async→ hidden performance tax -
Explicit tasks → clearer intent + lower overhead
