DotNext by Roman Sakno

<PackageReference Include="DotNext" Version="2.1.0" />

 ActionFuture<T>

sealed class ActionFuture<T> : AsyncDelegateFuture<Action<T>>
using System; using System.Runtime.CompilerServices; using System.Threading; namespace DotNext.Runtime.CompilerServices { [System.Runtime.CompilerServices.NullableContext(1)] [System.Runtime.CompilerServices.Nullable(new byte[] { 0, 1, 1 })] internal sealed class ActionFuture<[System.Runtime.CompilerServices.Nullable(2)] T> : AsyncDelegateFuture<Action<T>> { private readonly T arg; internal ActionFuture(T arg, CancellationToken token) : base(token) { this.arg = arg; } private protected override void InvokeOne(Action<T> handler) { handler(arg); } } }