mirror of
https://github.com/nushell/nushell.git
synced 2025-06-30 22:50:14 +02:00
Rename SyntaxShape::Custom
to CompleterWrapper
(#10548)
# Description The description `Custom` doesn't really reflect meaning in the set of `SyntaxShape`. Makes it a bit more verbose but explicit # User-Facing Changes Only hypothetically breaking as plugins can not effectively use a requirement on `SyntaxShape::Custom`. # Tests + Formatting (-)
This commit is contained in:
committed by
GitHub
parent
cc4f8bbd82
commit
9e445fd4c5
@ -2759,7 +2759,7 @@ pub fn parse_shape_name(
|
||||
let decl_id = working_set.find_decl(command_name);
|
||||
|
||||
if let Some(decl_id) = decl_id {
|
||||
return SyntaxShape::Custom(Box::new(shape), decl_id);
|
||||
return SyntaxShape::CompleterWrapper(Box::new(shape), decl_id);
|
||||
} else {
|
||||
working_set.error(ParseError::UnknownCommand(cmd_span));
|
||||
return shape;
|
||||
@ -4666,7 +4666,7 @@ pub fn parse_value(
|
||||
}
|
||||
|
||||
match shape {
|
||||
SyntaxShape::Custom(shape, custom_completion) => {
|
||||
SyntaxShape::CompleterWrapper(shape, custom_completion) => {
|
||||
let mut expression = parse_value(working_set, span, shape);
|
||||
expression.custom_completion = Some(*custom_completion);
|
||||
expression
|
||||
|
Reference in New Issue
Block a user