pub struct EnvParam {
pub owner: ObjectId,
pub param: ObjectId,
}Expand description
One hidden parameter of a lifted GNU nested function.
GCC gives a nested function a static chain — a pointer to the enclosing frame — and writes a trampoline when its address is taken. This crate lambda-lifts instead: each enclosing object the body uses becomes a pointer parameter of its own, the body reads and writes it through that pointer, and every call site passes the address of the object it has. The sharing C promises is therefore kept — a store in the nested function is visible in the enclosing one — without a trampoline, at the price of not being able to hand the function’s address out.
Fields§
§owner: ObjectIdThe enclosing function’s object the pointer carries.
param: ObjectIdThe *mut T (or *const T) parameter of this function that holds
its address.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for EnvParam
impl RefUnwindSafe for EnvParam
impl Send for EnvParam
impl Sync for EnvParam
impl Unpin for EnvParam
impl UnsafeUnpin for EnvParam
impl UnwindSafe for EnvParam
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more