mirror of https://github.com/golang/go.git
lexSpace consumed all spaces, even if the last one was part of a right delimiter like " -}}". Thus, "3 -}}" wouldn't lex as "3" and a right delimiter, but as "3", "-", and "}}". To fix that, make lexSpace stop if it encounters a right delimiter. Fixes #30948. Change-Id: I80a5546e5809e54f6823e2bf3a57a7e8808329be Reviewed-on: https://go-review.googlesource.com/c/go/+/168457 Reviewed-by: Daniel Martí <mvdan@mvdan.cc> |
||
|---|---|---|
| .. | ||
| scanner | ||
| tabwriter | ||
| template | ||