Skip to content

Commit

Permalink
Improve error readability
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 695442636
  • Loading branch information
txtpbfmt-copybara-robot committed Nov 11, 2024
1 parent 11f40bd commit 15de159
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion parser/parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@ func (p *parser) consumeOptionalSeparator() error {
if p.index > 0 && !p.isBlankSep(p.index-1) {
// If an unnamed field immediately follows non-whitespace, we require a separator character first (key_one:,:value_two instead of key_one::value_two)
if p.consume(':') {
return fmt.Errorf("parser encountered unexpected : character (should be whitespace, or a ,; separator)")
return fmt.Errorf("parser encountered unexpected character ':' (should be whitespace, ',', or ';')")
}
}

Expand Down

0 comments on commit 15de159

Please sign in to comment.