Toot

Written by Ruben Borg Nielsen on 2024-05-24 at 13:01

Today, I wasted 2 hours debugging what I thought was very odd behaviour in #csharp until I learned that async Task and async void are two very different things, and now I am very angry about async void. Was about to ban its usage entirely, but this SO article was helpful in explaining how it can be useful and not just a foot-gun

https://stackoverflow.com/questions/12144077/async-await-when-to-return-a-task-vs-void

=> More informations about this toot | View the thread | More toots from eldamir@hachyderm.io

Mentions

Tags

=> View csharp tag

Proxy Information
Original URL
gemini://mastogem.picasoft.net/toot/112496193547909693
Status Code
Success (20)
Meta
text/gemini
Capsule Response Time
348.045119 milliseconds
Gemini-to-HTML Time
1.954354 milliseconds

This content has been proxied by September (ba2dc).