Ephera@lemmy.ml to Rust Programming@lemmy.mlEnglish · 15 hours agoInheritance in 🦀lemmy.mlimagemessage-square3fedilinkarrow-up123arrow-down12cross-posted to: [email protected]
arrow-up121arrow-down1imageInheritance in 🦀lemmy.mlEphera@lemmy.ml to Rust Programming@lemmy.mlEnglish · 15 hours agomessage-square3fedilinkcross-posted to: [email protected]
minus-squaregoedelchen@mastodontech.delinkfedilinkarrow-up2·6 hours ago@Ephera that feels wrong, somehow … You can have the thing you are dereferencing to be a trait, so you can change your “base class” at runtime. At least, you can’t have multiple inheritance with impl Deref (I hope / as far as I can see)
@Ephera that feels wrong, somehow …
You can have the thing you are dereferencing to be a trait, so you can change your “base class” at runtime.
At least, you can’t have multiple inheritance with impl Deref (I hope / as far as I can see)