Re:If Inheritance is so bad, why does everyone use it?
by Sankozi on Friday April 12, 2024 @03:00AM
(#40010072)
You can have polymorphism without inheritance and inheritance without polymorphism. The big problem with inheritance is that it is really tricky to write those base classes. Making class inheritable by default in programming language is often considered a big mistake, because only carefully designed and documented class can be safely extended.
[ Parent
| on HN ]
There are no comments on this comment yet.