pub trait DefaultRef {
// Required method
fn default_ref<'a>() -> &'a Self;
}
Expand description
Allows creating a default reference to a type.
Required Methods§
Sourcefn default_ref<'a>() -> &'a Self
fn default_ref<'a>() -> &'a Self
Creates a reasonable default reference for this type.
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.