Skip to content

Commit

Permalink
Throw correct error when an unimplemented command is used with arguments
Browse files Browse the repository at this point in the history
Fixes #7207
  • Loading branch information
J-Fields committed Oct 29, 2021
1 parent 9712a77 commit b58bb6e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/vimscript/exCommandParser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -632,7 +632,7 @@ function nameParser(
name: [string, string],
argParser: ArgParser | undefined
): Parser<Parser<ExCommand>> {
argParser ??= succeed(new UnimplementedCommand(name[1] ? `${name[0]}[${name[1]}]` : name[0]));
argParser ??= all.result(new UnimplementedCommand(name[1] ? `${name[0]}[${name[1]}]` : name[0]));

const fullName = name[0] + name[1];
const p = nameAbbrevParser(name[0], name[1]).result(argParser);
Expand Down

0 comments on commit b58bb6e

Please sign in to comment.