Allow rest vars to have a custom name

This commit is contained in:
JT
2021-09-07 15:37:02 +12:00
parent 8f54ba10aa
commit bdce34676a
7 changed files with 77 additions and 16 deletions

View File

@ -27,7 +27,7 @@ fn test_signature_chained() {
)
.named("named", SyntaxShape::String, "named description", Some('n'))
.switch("switch", "switch description", None)
.rest(SyntaxShape::String, "rest description");
.rest("rest", SyntaxShape::String, "rest description");
assert_eq!(signature.required_positional.len(), 1);
assert_eq!(signature.optional_positional.len(), 1);