nushell/crates/nu-protocol/src/engine/mod.rs
Stefan Holderbach ec528c0626
Refactor source cache into CachedFile struct (#12240)
# Description
Get rid of two parallel `Vec`s in `StateDelta` and `EngineState`, that
also duplicated span information. Use a struct with documenting fields.

Also use `Arc<str>` and `Arc<[u8]>` for the allocations as they are
never modified and cloned often (see #12229 for the first improvement).
This also makes the representation more compact as no capacity is
necessary.

# User-Facing Changes
API breakage on `EngineState`/`StateWorkingSet`/`StateDelta` that should
not really affect plugin authors.
2024-03-20 19:43:50 +01:00

28 lines
486 B
Rust

mod cached_file;
mod call_info;
mod capture_block;
mod command;
mod engine_state;
mod overlay;
mod pattern_match;
mod stack;
mod state_delta;
mod state_working_set;
mod stdio;
mod usage;
mod variable;
pub use cached_file::CachedFile;
pub use call_info::*;
pub use capture_block::*;
pub use command::*;
pub use engine_state::*;
pub use overlay::*;
pub use pattern_match::*;
pub use stack::*;
pub use state_delta::*;
pub use state_working_set::*;
pub use stdio::*;
pub use variable::*;