StardustPL / Stardust

"A programming language that doesn't make me angry to use it."
https://StardustPL.GitHub.IO/
The Unlicense
4 stars 0 forks source link

Planning: inheritance, mixins, and bases #31

Open LB-- opened 8 years ago

LB-- commented 8 years ago

Inheritance

In all cases, multiple inheritance/mixins/bases is/are allowed.

Inheritance is like traditional C++ inheritance, except that CRTP isn't possible. Mixins are designed for CRTP and are aware of the type they are being mixed into. Bases don't know they're being used as a base, and they can't stop it from happening.

LB-- commented 8 years ago

You can alter inherited/mixed-in/based members in compatible ways without having to give entirely new definitions (e.g. just change the privacy, mark final, add or remove virtual, etc)