mirror of
https://github.com/nushell/nushell.git
synced 2025-01-11 00:38:23 +01:00
Improve missing param error span (#4560)
This commit is contained in:
parent
a32ce93c79
commit
9ea5a2ecd3
@ -114,7 +114,10 @@ pub fn check_call(command: Span, sig: &Signature, call: &Call) -> Option<ParseEr
|
||||
} else {
|
||||
return Some(ParseError::MissingPositional(
|
||||
argument.name.clone(),
|
||||
command,
|
||||
Span {
|
||||
start: command.end,
|
||||
end: command.end,
|
||||
},
|
||||
sig.call_signature(),
|
||||
));
|
||||
}
|
||||
@ -134,7 +137,10 @@ pub fn check_call(command: Span, sig: &Signature, call: &Call) -> Option<ParseEr
|
||||
} else {
|
||||
Some(ParseError::MissingPositional(
|
||||
missing.name.clone(),
|
||||
command,
|
||||
Span {
|
||||
start: command.end,
|
||||
end: command.end,
|
||||
},
|
||||
sig.call_signature(),
|
||||
))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user