Override generic methods in c#
Posted
by
Pascal
on Stack Overflow
See other posts from Stack Overflow
or by Pascal
Published on 2012-08-28T21:29:16Z
Indexed on
2012/08/28
21:38 UTC
Read the original article
Hit count: 195
I thought I can not override generic methods of a derived class.
http://my.safaribooksonline.com/book/programming/csharp/9780071741163/generics/ch18lev1sec13
The code in this link runs fine. The overriden method is called although the instance type of
the base class is used and not the instance of the derived type.
Now I am confused because a former question of mine Type parameter declaration must be identifier not a type
is about calling the overriding generic method with the instance of base type which did NOT work!
© Stack Overflow or respective owner