go/scanner: minimal non-terminated literals
Consume as little as possible input when encountering non-terminated rune, string, and raw string literals. The old code consumed at least one extra character which could lead to worse error recovery when parsing erroneous sources. Also made error messages in those cases more consistent. Fixes #7091. R=adonovan CC=golang-codereviews https://golang.org/cl/50630043
Showing
Please register or sign in to comment