21
submitted 9 months ago by Ephera@lemmy.ml to c/rust@lemmy.ml
you are viewing a single comment's thread
view the rest of the comments
[-] goedelchen@mastodontech.de 6 points 9 months 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)

this post was submitted on 01 Feb 2026
21 points (83.9% liked)

Rust Programming

9435 readers
1 users here now

founded 7 years ago
MODERATORS