mirror of
https://github.com/nushell/nushell.git
synced 2025-02-22 21:41:26 +01:00
# Description This PR replaces most of the constants in `ResolvedImportPattern` from values to VarIds, this has benefits of: 1. less duplicated variables in state 2. precise span of variable, for example when calling `goto def` on a const imported by the `use` command, this allows it to find the original definition, instead of where the `use` command is. Note that the logic is different here for nested submodules, not all values are flattened and propagated to the outmost record variable, but I didn't find any differences in real world usage. I noticed that it was changed from `VarId` to `Value` in #10049. Maybe @kubouch can find some edge cases where this PR fails to work as expected. In my view, the record constants for `ResolvedImportPattern` should even reduced to single entry, if not able to get rid of. # User-Facing Changes # Tests + Formatting # After Submitting |
||
---|---|---|
.. | ||
src | ||
tests | ||
Cargo.toml | ||
LICENSE | ||
README.md |
nu-protocol
The nu-protocol crate holds the definitions of structs/traits that are used throughout Nushell. This gives us one way to expose them to many other crates, as well as make these definitions available to each other, without causing mutually recursive dependencies.