Skip to main content

HasRefCountUpgradeable

Trait HasRefCountUpgradeable 

Source
pub trait HasRefCountUpgradeable: HasRefCount { }
Expand description

Trait for an object to mark itself as allowing the make_ref_ptr_upgrade_from_raw operation, which can be used to give weak-pointer like behavior for very specific use cases.

Although an object does not need to do anything additional to support this trait, it requires an explicit implementation as this is only intended to resolve certain specific circular dependencies.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§