New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmd/vet: should not warn +build in raw string literal #21716
Comments
I think this is intentional (ie. WAI), because some go tools are known to not parse the source when looking for [certain?] magic comments. The solution is to, for example
or to use any other way of hiding the directive in it's plain form and starting at BOL. |
If this is the case we probably need to change |
Change https://golang.org/cl/60776 mentions this issue: |
Appease the vet builder until we figure out the ideal solution. Updates #21716. Change-Id: I64ecdf9b6efb0933c5c79e11c860966ff1980305 Reviewed-on: https://go-review.googlesource.com/60776 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Keith Randall <khr@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
We've worked around this issue in hilbert_test.go for now to appease the vet builder. If we decide to fix in cmd/vet instead, we should undo the workaround. |
Working as intended. |
After CL 60531 (https://go-review.googlesource.com/c/go/+/60531), the misc builder fails with
(https://build.golang.org/log/890387a04a58201c9d1cf7d819dbe939e3e5d4b0)
The relevant line is https://go-review.googlesource.com/c/go/+/60531/2/src/go/types/hilbert_test.go#55
which is a +build in raw string literal.
The text was updated successfully, but these errors were encountered: