pub trait FarWith<T>where
T: ?Sized,{
// Required method
fn there<C, R>(
&self,
anchor: Anchor,
outer: &mut Bank<C>,
f: impl FnOnce(&T) -> R,
) -> R
where C: Group,
R: BankSafe;
}Available on crate feature
bank only.Expand description
Borrowing a far pointer’s data across a bank boundary.
Switches into the data’s bank, lends &T to f, then restores the caller C:
the cross-bank counterpart of Far::local. Implemented by Far (switch via
scope, then local) and DynFar (switch to its runtime bank).
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".