pub struct SubshFdFrame { /* private fields */ }Expand description
The descriptors a bare exec redirection moved inside an in-process
subshell, each with a copy of what it was before, and the ones the body
opened for itself ({var}, sysopen -u, zsystem flock -f).
!!! WARNING: RUST-ONLY TYPE — C forks and needs none of this !!!
exec 3>file / exec 3>&- with no command is permanent — c:4035
“specifically don’t restore the original fd’s” — but inside
$( … ) or ( … ) it is permanent only for the forked child
(Src/exec.c:4816, c:2880), whose fd table dies with it. zshrs runs
the body in process, so the parent’s descriptors are saved here the
first time the body’s permanent redirection touches each one, and put
back when the frame is dropped; a descriptor from 10 up that the body
allocated is closed, as the child’s exit would ((exec {v}>f); exec {w}>g gives w 11 in zsh). A body that redirects nothing permanently
costs nothing.
Implementations§
Trait Implementations§
Source§impl Drop for SubshFdFrame
impl Drop for SubshFdFrame
Auto Trait Implementations§
impl Freeze for SubshFdFrame
impl RefUnwindSafe for SubshFdFrame
impl Send for SubshFdFrame
impl Sync for SubshFdFrame
impl Unpin for SubshFdFrame
impl UnsafeUnpin for SubshFdFrame
impl UnwindSafe for SubshFdFrame
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more