Trait objects: Blocking entire traits vs blocking members


#21

Well, for me there is nothing unsafe here. If we are happy with two keyword prefixes, maybe dyn struct Trait would be a go: sementically this thing is an ad-hoc struct that wrap a trait object may or may not be a dyn Trait inside.

Would this be necessory? I guess a definition like "dyn struct Trait means the same as dyn Trait if Trait is object safe" would be enough.

This should be a warning, as I proposed.


#22

7 posts were split to a new topic: What is the difference between impl Trait and dyn Trait?