Description
System.Threading.Task<T> has a custom debug proxy. This debug proxy returns default value of T instead of indicating a potential exception for a Result property of a faulted task
Reproduction Steps
var mt = M();
await ((Task)mt).ConfigureAwait(ConfigureAwaitOptions.SuppressThrowing);
Console.WriteLine(mt.Result);
async Task<string> M()
{
throw new NotImplementedException();
}
- Break point on
Console... line.
- Start debugging
- Reach the break point and inspect
Result property
Expected behavior
Debug proxy indicates that accessing Result will throw an exception
Actual behavior
Result shows default value (in this case null), misleading developers about actual property behavior:

Regression?
No
Known Workarounds
No response
Configuration
No response
Other information
No response