This change adds `Sized` as a supertrait of our `SealedInternal` trait, to ensure that our codegen traits cannot be used as trait objects (i.e. with `dyn`). I was thinking it would be prudent to do this early so that we don't end up accidentally forced to support `dyn` usage. Some of the traits already disallowed `dyn` as a result of having `Sized` as an indirect supertrait or for other reasons, but a few traits did allow trait objects. If we ever do want to support some kind of type-erased message, I suspect we will want to provide our own implementation. At least for C++, we already have a vtable in the kernel, so it would seem wasteful to have Rust duplicate it. PiperOrigin-RevId: 692195274pull/19074/head
parent
d2f4410107
commit
51e2664f2f
1 changed files with 5 additions and 2 deletions
Loading…
Reference in new issue