pub unsafe trait HasGroup<Data> {
// Required methods
unsafe fn group(this: *const Self) -> *const config_group;
unsafe fn container_of(group: *const config_group) -> *const Self;
}
Expand description
Trait that allows offset calculations for structs that embed a
bindings::config_group
.
Users of the configfs API should not need to implement this trait.
§Safety
- Implementers of this trait must embed a
bindings::config_group
. - Methods must be implemented according to method documentation.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.