-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Open
Labels
area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMICLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
Milestone
Description
Example from @MichalStrehovsky:
using System;
using System.Runtime.CompilerServices;
using System.Threading.Tasks;
using Xunit;
public class StaticVirtual
{
interface IHaveStaticVirtuals
{
static abstract Task DoTask();
}
class ClassWithStaticVirtuals : IHaveStaticVirtuals
{
public static async Task DoTask() => await Task.Yield();
}
static async Task CallDoTask<T>() where T : IHaveStaticVirtuals => await T.DoTask();
[Fact]
public static void TestEntryPoint()
{
CallDoTask<ClassWithStaticVirtuals>().Wait();
}
}We see task-returning thunk created for DoTask. This is a regression introduced by #124283. We do not properly detect that this is a virtual call.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMICLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI