Skip to content

WaleedNaveed/Stop-inheritance-of-class-without-using-Sealed-KeyWord

Repository files navigation

In this program i have created a class and developed it in such a way that other classes can not inherit from it. This can be done using "Sealed" keyword in C# but, i have not used "Sealed" keyword. We get a compile time error when we try to inherit a class from a "Sealed" class. But in my program we get a run-time error. This program is developed in such a way that no compile time error will be thrown but a run-time error will be thrown at the time of assigning child class object to parent class reference.

About

Make a class non-inheritable without using Sealed keyword

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages