Beef
Beef copied to clipboard
Cannot access inherited property on derived interface
interface IParent
{
bool IsEnabled {get; set;}
}
interface IChild : IParent
{
}
class Implementation : IChild{
public bool IsEnabled {get; set;}
}
class Program
{
public static void Main()
{
IChild c = scope Implementation();
var enabled = c.IsEnabled;
}
}
A compiler error is reported by the line: var enabled = c.IsEnabled;