nushell/crates/nu-protocol/src
Devyn Cairns aa9a42776b
Make ast::Call::span() and arguments_span() more robust (#13412)
# Description

Trying to help @amtoine out here - the spans calculated by `ast::Call`
by `span()` and `argument_span()` are suspicious and are not properly
guarding against `end` that might be before `start`. Just using
`Span::merge()` / `merge_many()` instead to try to make the behaviour as
simple and consistent as possible. Hopefully then even if the arguments
have some crazy spans, we don't have spans that are just totally
invalid.

# Tests + Formatting
I did check that everything passes with this.
2024-07-19 05:12:19 -07:00
..
ast Make ast::Call::span() and arguments_span() more robust (#13412) 2024-07-19 05:12:19 -07:00
config Document public types in nu-protocol (#12906) 2024-07-11 13:30:12 +02:00
debugger Overhaul $in expressions (#13357) 2024-07-17 16:02:42 -05:00
engine Remove unused field in StateWorkingSet (#13387) 2024-07-16 11:28:31 +02:00
errors Deprecate group in favor of chunks (#13377) 2024-07-16 03:49:00 +00:00
ir Make plugins able to find and call other commands (#13407) 2024-07-19 13:54:21 +08:00
pipeline Deprecate group in favor of chunks (#13377) 2024-07-16 03:49:00 +00:00
plugin remove the deprecated register command (#13297) 2024-07-05 07:16:50 -05:00
process Document public types in nu-protocol (#12906) 2024-07-11 13:30:12 +02:00
value Document public types in nu-protocol (#12906) 2024-07-11 13:30:12 +02:00
alias.rs Document public types in nu-protocol (#12906) 2024-07-11 13:30:12 +02:00
did_you_mean.rs Improve case insensitivity consistency (#10884) 2023-11-08 23:58:54 +01:00
eval_base.rs Overhaul $in expressions (#13357) 2024-07-17 16:02:42 -05:00
eval_const.rs Use directories for autoloading (#13382) 2024-07-19 03:47:07 -07:00
example.rs Overhaul the plugin cache file with a new msgpack+brotli format (#12579) 2024-04-21 07:36:26 -05:00
id.rs Internal representation (IR) compiler and evaluator (#13330) 2024-07-10 17:33:59 -07:00
lev_distance.rs Rework for new clippy lints (#12736) 2024-05-02 19:29:03 +02:00
lib.rs Add top-level crate documentation/READMEs (#12907) 2024-07-14 10:10:41 +02:00
module.rs Enable reloading changes to a submodule (#13170) 2024-06-25 18:33:37 -07:00
parser_path.rs Enable reloading changes to a submodule (#13170) 2024-06-25 18:33:37 -07:00
signature.rs Document public types in nu-protocol (#12906) 2024-07-11 13:30:12 +02:00
span.rs Document public types in nu-protocol (#12906) 2024-07-11 13:30:12 +02:00
syntax_shape.rs open, rm, umv, cp, rm and du: Don't globs if inputs are variables or string interpolation (#11886) 2024-02-23 09:17:09 +08:00
ty.rs Deprecate group in favor of chunks (#13377) 2024-07-16 03:49:00 +00:00