Skip to main content

Module engine

Module engine 

Source
Expand description

Representation of the engine state and many of the details that implement the scoping

Structs§

ArgumentStack
Stores the argument context for calls in IR evaluation.
CachedFile
Unit of cached source code
Call
This is a HACK to help Command support both the old AST evaluator and the new IR evaluator at the same time. It should be removed once we are satisfied with the new evaluator.
Closure
CurrentJob
Stores the information about the background job currently being executed by this thread, if any
EngineState
The core global engine state. This includes all global definitions as well as any global state that will persist for the whole session.
EnvName
A String that’s case-insensitive for all environment variable names, used for environment variable names.
ErrorHandler
Describes an error handler stored during IR evaluation.
ErrorHandlerStack
Keeps track of error handlers pushed during evaluation of an IR block.
ExperimentalMarkerDeprecated
Marker type for tagging Command methods as experimental.
FileStack
Files being evaluated, arranged as a stack.
FrozenJob
IsDebugging
Jobs
Mailbox
OverlayFrame
PromptContents
The full set of rendered prompt strings, as the line editor draws them.
PromptState
Shared, thread-safe home for the interactive prompt’s rendered content.
ReplState
ScopeBindings
Name bindings introduced while parsing a single block/closure scope.
ScopeFrame
Sequence
Implements an atomically incrementing sequential series of numbers
Stack
A runtime value stack used during evaluation
StackCallArgGuard
StackCollectValueGuard
StackIoGuard
StackWithInvocation
RAII wrapper that records a custom command’s return-value OutDest on a Stack.
StateDelta
A delta (or change set) between the current global state and a possible future global state. Deltas can be applied to the global state to update it to contain both previous state and the state held within the delta.
StateWorkingSet
A temporary extension to the global state. This handles bridging between the global state and the additional declarations and scope changes that are not yet part of the global scope.
ThreadJob
UnevaluatedCallInfo
Variable
Visibility
Tells whether a decl is visible or not

Enums§

ArgType
Argument
Represents a fully evaluated argument to a call.
CallImpl
CommandType
Job
PromptSegment
Which prompt segment an asynchronous PromptState::set targets.
Redirection
VirtualPath

Constants§

ENV_VARIABLE_ID
IN_VARIABLE_ID
LAST_RESULT_VAR_NAME
Identifier for the last-result special variable without the $ sigil.
LAST_VARIABLE_ID
Interactive last-result special variable.
NU_VARIABLE_ID
UNKNOWN_SPAN_ID

Statics§

DEFAULT_OVERLAY_NAME
UPDATE_CWD
Configure whether the current working directory may be updated when EngineState::merge_env is called.

Traits§

Command
CommandClone
Matcher

Functions§

invalid_regex_value
Map a fancy-regex compile failure to ShellError::InvalidValue.

Type Aliases§

EnvVars
Environment variables per overlay
FilterTag
Mail