BepInEx / Il2CppInterop

A tool interoperate between CoreCLR and Il2Cpp at runtime
GNU Lesser General Public License v3.0
185 stars 59 forks source link

[Generator] Delegate conversions with generic params are broken #120

Closed slxdy closed 1 month ago

slxdy commented 4 months ago

Idk how to describe it well, so I think the following Il2CppInterop-generated piece speaks for itself. At Il2CppSystem.Comparison<>:

public static implicit operator Comparison<T>(System.Func<,> P_0)
{
    return DelegateSupport.ConvertDelegate<Comparison<T>>(P_0);
}

The parameter type does not specify the generic arguments

ds5678 commented 1 month ago

What game is this?

ds5678 commented 1 month ago

For The Long Dark, that method looks fine:

public static implicit operator Comparison<T>(System.Func<T, T, int> P_0)
{
    return DelegateSupport.ConvertDelegate<Comparison<T>>(P_0);
}
ds5678 commented 1 month ago

I think this was fixed by #132.