Skip to content

[RuntimeAsync] MethodInfo.GetMethodBody fails with AF:MayHaveILHeader() #118319

@jkotas

Description

@jkotas

Repro

Compile and run with runtime async enabled:

using System.Threading.Tasks;

public class Test
{
   static void Main() {
        typeof(Test).GetMethod("M").GetMethodBody();
   }

   public async Task M() {
       await Task.Delay(1);
   }
}

Result

Assert failure(PID 38644 [0x000096f4], Thread: 39468 [0x9a2c]): Precondition failure:
FAILED: MayHaveILHeader()

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions