We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b2fe360 commit 69035d7Copy full SHA for 69035d7
1 file changed
ValidCode/Async.cs
@@ -82,6 +82,18 @@ public async Task Calls()
82
await System.Windows.Threading.Dispatcher.CurrentDispatcher.Invoke(() => Task.FromResult(42)).ConfigureAwait(false);
83
}
84
85
+ public static Task<IDisposable> TaskFromResult()
86
+ {
87
+ var disposable = new Disposable();
88
+ return Task.FromResult<IDisposable>(disposable);
89
+ }
90
+
91
+ public static ValueTask<IDisposable> ValueTask()
92
93
94
+ return new ValueTask<IDisposable>(disposable);
95
96
97
public static async Task<string?> Bar1Async()
98
{
99
using (var stream = await ReadAsync(string.Empty))
0 commit comments