Skip to content

Commit dc6b5cb

Browse files
committed
jsondocck: Better error for invalid @count number
1 parent 42b548c commit dc6b5cb

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Diff for: src/tools/jsondocck/src/main.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,10 @@ impl CommandKind {
7373

7474
if let CommandKind::Count = self {
7575
if args[2].parse::<usize>().is_err() {
76-
print_err(&format!("Third argument to @count must be a valid usize"), lineno);
76+
print_err(
77+
&format!("Third argument to @count must be a valid usize (got `{}`)", args[2]),
78+
lineno,
79+
);
7780
return false;
7881
}
7982
}

0 commit comments

Comments
 (0)