От: | Uzzy | ||
Дата: | 14.08.09 09:32 | ||
Оценка: |
public class A
{
}
public class C : A
{
public event EventHandler Modified;
}
public class F<T>
where T : A
{
private readonly T owner;
public F(T owner)
{
this.owner = owner;
}
public T Owner { get { return owner; } }
}
public class G : F<C>
{
public G(C owner)
: base(owner)
{
Owner.Modified += (o, e) => A();
}
private static void A()
{
}
}
class Program
{
static void Main(string[] args)
{
C c = new C();
G g = new G(c);
}
}
warning CS0067: The event 'TestConsole.C.Modified' is never used