Repair off-by-one in error message

This commit is contained in:
Tony Garnock-Jones 2021-10-07 21:29:13 +02:00
parent 733037f41b
commit c51f6b2a4e
1 changed files with 2 additions and 2 deletions

View File

@ -654,8 +654,8 @@ impl<'t> Parser<'t> {
self.drop();
if s.len() > 0 {
let m = format!("Invalid use of pattern binder in target: {:?}", self.peek());
return self.error(m);
return self.error(format!(
"Invalid use of pattern binder in target: ?{}", s));
}
if self.ateof() {