News for hackers. Stuff that matters.
Re:UML: My Part in Its Downfall by arethuza on Tuesday October 04, 2022 @05:12AM (#33078024)
"derived class actively "points to" its base class"

That make sense - pretty much every language I've used that supports inheritance class definitions refer to the class (or classes) they extend rather than the other way about.

Re:UML: My Part in Its Downfall by Ensorceled on Tuesday October 04, 2022 @06:45AM (#33078586)
I like it ...

class Vehicle extendedBy Car, Truck

class Car

class Truck extendedBy Semi

class Semi

This would be almost as awesome as "comefrom"[1]

[1] https://en.wikipedia.org/wiki/COMEFROM

Re:UML: My Part in Its Downfall by fhars on Tuesday October 04, 2022 @07:10AM (#33078751)
Re:UML: My Part in Its Downfall by zozbot234 on Tuesday October 04, 2022 @07:27AM (#33078882)
You could use a generic Vehicle<T: VehicleType>, with Vehicle<Car>, Vehicle<Truck>, Vehicle<Semi> implementing specialized interfaces.