pub enum CompoundCommand {
Grouping(List),
Subshell {
body: Rc<List>,
location: Location,
},
For {
name: Word,
values: Option<Vec<Word>>,
body: List,
},
While {
condition: List,
body: List,
},
Until {
condition: List,
body: List,
},
If {
condition: List,
body: List,
elifs: Vec<ElifThen>,
else: Option<List>,
},
Case {
subject: Word,
items: Vec<CaseItem>,
},
}
Expand description
Command that contains other commands
Variants§
Grouping(List)
List as a command
Subshell
Command for executing commands in a subshell
For
For loop
While
While loop
Until
Until loop
If
If conditional construct
Case
Case conditional construct
Trait Implementations§
Source§impl Clone for CompoundCommand
impl Clone for CompoundCommand
Source§fn clone(&self) -> CompoundCommand
fn clone(&self) -> CompoundCommand
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for CompoundCommand
impl Debug for CompoundCommand
Source§impl Display for CompoundCommand
impl Display for CompoundCommand
Source§impl FromStr for CompoundCommand
Converts a string to a compound command.
impl FromStr for CompoundCommand
Converts a string to a compound command.
Source§impl PartialEq for CompoundCommand
impl PartialEq for CompoundCommand
impl Eq for CompoundCommand
impl StructuralPartialEq for CompoundCommand
Auto Trait Implementations§
impl Freeze for CompoundCommand
impl !RefUnwindSafe for CompoundCommand
impl !Send for CompoundCommand
impl !Sync for CompoundCommand
impl Unpin for CompoundCommand
impl !UnwindSafe for CompoundCommand
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
Converts
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>
Converts
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