Trait supercow::DefaultFeatures
[−]
[src]
pub trait DefaultFeatures<'a>: Send + Sync + 'a {
fn clone_boxed(&self) -> Box<DefaultFeatures<'a> + 'a>;
fn self_address_mut(&mut self) -> *mut ();
}The default shared reference type for Supercow.
This requires the shared reference type to be Clone, Send, and
Sync, which thus disqualifies using Rc. This was chosen as the
default since the inability to use Rc is generally a less subtle
issue than the Supercow not being Send or Sync.
See also NonSyncFeatures.
Required Methods
fn clone_boxed(&self) -> Box<DefaultFeatures<'a> + 'a>
Clone this value, and then immediately put it into a Box
behind a trait object of this trait.
fn self_address_mut(&mut self) -> *mut ()
Returns the address of self.
This is used to disassemble trait objects of this trait without
resorting to transmuting or the unstable TraitObject type.