nushell/crates/nu-cli/src
Ian Manske 60da7abbc7
Use Vec for Closure captures (#10940)
# Description
Changes the `captures` field in `Closure` from a `HashMap` to a `Vec`
and makes `Stack::captures_to_stack` take an owned `Vec` instead of a
borrowed `HashMap`.

This eliminates the conversion to a `Vec` inside `captures_to_stack` and
makes it possible to avoid clones altogether when using an owned
`Closure` (which is the case for most commands). Additionally, using a
`Vec` reduces the size of `Value` by 8 bytes (down to 72).

# User-Facing Changes
Breaking API change for `nu-protocol`.
2023-11-08 00:43:28 +01:00
..
commands Add long options for platform and random (#10776) 2023-10-19 22:04:33 +02:00
completions Return external file completions if not empty (#10898) 2023-10-31 11:32:21 -05:00
menus Add themes to help command when available #10318 (#10623) 2023-10-10 07:40:05 -05:00
config_files.rs Fix config creation during printing (#9353) 2023-06-04 22:04:28 +03:00
eval_cmds.rs Move CLI related commands to nu-cli (#8832) 2023-04-10 10:56:47 +12:00
eval_file.rs allow early return outside of main (#10514) 2023-09-28 18:49:42 +02:00
lib.rs cratification: move the bytes command to nu-cmd-extra (#9509) 2023-06-23 12:23:08 -07:00
nu_highlight.rs Move Value to helpers, separate span call (#10121) 2023-09-03 07:27:29 -07:00
print.rs allow print to take data as input again (#9823) 2023-07-27 21:40:25 +02:00
prompt_update.rs Use Vec for Closure captures (#10940) 2023-11-08 00:43:28 +01:00
prompt.rs Fix default prompt indicators (#9914) 2023-08-05 04:47:46 +12:00
reedline_config.rs Use Vec for Closure captures (#10940) 2023-11-08 00:43:28 +01:00
repl.rs Make hints aware of the current directory (#10780) 2023-10-20 11:21:58 +02:00
syntax_highlight.rs Use slices directly instead of &Vec (#10328) 2023-09-12 11:38:20 +08:00
util.rs Move Value to helpers, separate span call (#10121) 2023-09-03 07:27:29 -07:00
validation.rs Remove old alias implementation (#8797) 2023-04-07 21:09:38 +03:00