1
0
mirror of https://github.com/golang/go synced 2024-11-18 11:04:42 -07:00

cmd/goyacc: append trailing newline to text "Code generated by goyacc"

Fixes golang/go#26478

Change-Id: Ieaf7dcaf639b277555580964acfff034393284e2
GitHub-Last-Rev: f2a6ab2a513d4938cda62f46de7f5314714b5325
GitHub-Pull-Request: golang/tools#39
Reviewed-on: https://go-review.googlesource.com/124995
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
Jim Minter 2018-07-19 18:17:40 +00:00 committed by Brad Fitzpatrick
parent 54f9f5980a
commit 4735f53fb3

View File

@ -387,7 +387,7 @@ func setup() {
yaccpar = strings.Replace(yaccpartext, "$$", prefix, -1)
openup()
fmt.Fprintf(ftable, "// Code generated by goyacc %s. DO NOT EDIT.", strings.Join(os.Args[1:], " "))
fmt.Fprintf(ftable, "// Code generated by goyacc %s. DO NOT EDIT.\n", strings.Join(os.Args[1:], " "))
defin(0, "$end")
extval = PRIVATE // tokens start in unicode 'private use'