How to use base class & child class as parameter in one function ?

Vinod K Chandran kcvinu82 at gmail.com
Fri May 22 13:10:46 UTC 2020


On Friday, 22 May 2020 at 12:21:25 UTC, rikki cattermole wrote:
> if (Child child = cast(Child)parent) {
> 	assert(child !is null);
> }

Actually, problem occurs in addHandler function. It expects an 
argument of type "EventArgs", not MouseEventArgs.


More information about the Digitalmars-d-learn mailing list