Skip to content

Instantly share code, notes, and snippets.

@xavierarpa
Created January 12, 2024 14:51
Show Gist options
  • Save xavierarpa/fd269f28eaacc3771d0c94b0c5d516d0 to your computer and use it in GitHub Desktop.
Save xavierarpa/fd269f28eaacc3771d0c94b0c5d516d0 to your computer and use it in GitHub Desktop.
IntExtensions.cs
using System.Runtime.CompilerServices;
using System.Threading.Tasks;
public static class IntExtensions
{
public static TaskAwaiter GetAwaiter(this int number)
{
return Task.Delay(number * 1000).GetAwaiter();
}
}
// await 5;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment