Remove GetWaiterTask allocation for display class (dotnet/corefx#39411)
authorStephen Toub <stoub@microsoft.com>
Fri, 12 Jul 2019 00:28:47 +0000 (20:28 -0400)
committerGitHub <noreply@github.com>
Fri, 12 Jul 2019 00:28:47 +0000 (20:28 -0400)
commit3f5503e4abcb7692139b014e355bba6ad56b7c27
treed1ab8db5070d3c78044e9af51600a6e4b83f2356
parentd646cc5697802fc06b62e33e50a8aa01bccc51ed
Remove GetWaiterTask allocation for display class (dotnet/corefx#39411)

Using an async local function here that accesses its outer function's state is resulting in the compiler allocating a display class at the beginning of GetWaiterTask.

Commit migrated from https://github.com/dotnet/corefx/commit/59b60a232ecf3df2319fadd0193f5dcb42948e29
src/libraries/System.Net.Http/src/System/Net/Http/SocketsHttpHandler/Http2Stream.cs