News for hackers. Stuff that matters.
Re:Asynchronous Programming in C# by MarkSweep on Friday September 24, 2021 @12:29PM (#28644634)
The other reason those Parallel methods did use async/await is that async/await did not exist in .NET at the time those methods were introduced.

But good news! The upcoming .NET 6 release will have a Parallel.ForEachAsync method:

https://docs.microsoft.com/dotnet/api/system.threading.tasks...

Re:Asynchronous Programming in C# by torginus on Friday September 24, 2021 @03:13PM (#28646620)
Doing a bit of .NET archeology we find that both Task<T> and Parallel.For can be dated to .NET 4.0 So if they wanted to, they could've included async/await support. It just didn't make sense.
Re:Asynchronous Programming in C# by ridethebike on Friday September 24, 2021 @03:35PM (#28646849)
Async/await were officially added to c# 5 and .net framework 4.5

I think it was possible to have async/await in .net framework 4.0 via some workarounds when it was still in CTP mode but I don't recall the details.