Module brush_parser::ast
source · Expand description
Defines the Abstract Syntax Tree (ast) for shell programs. Includes types and utilities for manipulating the AST.
Structs§
- Represents a sequence of command pipelines connected by boolean operators.
- An arithmetic command, evaluating an arithmetic expression.
- An arithmetic for clause, which loops until an arithmetic condition is reached.
- Encapsulates an assignment declaration.
- A brace group, which groups commands together.
- A case clause, which selects a command based on a value and a set of pattern-based filters.
- An individual matching case item in a case clause.
- Represents a prefix to a simple command.
- Represents a suffix to a simple command; a word argument, declaration, or I/O redirection.
- A sequence of commands.
- An element of a compound command list.
- A do group, which groups commands together.
- Represents the
elseclause of a conditional command. - A for clause, which loops over a set of values.
- Encapsulates the body of a function definition.
- Encapsulates the definition of a shell function.
- An if clause, which conditionally executes a command.
- Represents an I/O here document.
- A pipeline of commands, where each command’s output is passed as standard input to the command that follows it.
- Represents a complete shell program.
- A list of I/O redirections to be applied to a command.
- Represents the invocation of a simple command.
- A subshell, which executes commands in a subshell.
- Encapsulates an unparsed arithmetic expression.
- A while or until clause, whose looping is controlled by a condition.
- Represents a shell word.
Enums§
- Represents a boolean operator used to connect command pipelines, along with the succeeding pipeline.
- An arithmetic expression.
- Identifies the target of an arithmetic assignment expression.
- The target of an assignment.
- A value being assigned to a variable.
- A binary arithmetic operator.
- A binary predicate usable in an extended test expression.
- Represents a shell command.
- A prefix or suffix for a simple command.
- Represents a compound command, potentially made up of multiple nested commands.
- An extended test expression.
- Kind of file I/O redirection.
- Target for an I/O file redirection.
- An I/O redirection.
- Indicates whether the preceding command is executed synchronously or asynchronously.
- A (non-extended) test expression.
- A unary arithmetic assignment operator.
- A unary arithmetic operator.
- A unary predicate usable in an extended test expression.
Type Aliases§
- Represents a complete shell command.
- Represents a complete shell command item.