pub trait MethodsDeclared { }Expand description
Marker emitted by #[derive(RepeStruct)] when the struct carries the
#[repe(methods)] attribute.
A derive macro cannot see impl blocks, so the two halves of the
#[repe::methods] surface are tied together by a compile-time handshake.
This marker is a supertrait of RepeMethods, so the table the attribute
macro generates simply cannot be implemented for a struct that did not
declare it — no assertion to emit, and none to forget. Missing either half is
a compile error naming the attribute that is absent, rather than a method
that quietly never reaches the wire.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".