We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
go version
$ go version go version go1.12 windows/amd64
main.go
package main import ( "unsafe" ) /* void cgofoo(void* a, int b) {} */ import "C" func foo() { var p unsafe.Pointer C.cgofoo(nil, (C.int)( 0)) C.cgofoo(p, (C.int)(0)) // syntax error: unexpected semicolon, expecting expression C.cgofoo(p, (C.int)( 0)) } func main() {}
build success, but go 1.11.4 is ok.
main.go:21:27: syntax error: unexpected semicolon, expecting expression
The text was updated successfully, but these errors were encountered:
Thanks for reporting this.
This is related to #29748 and #29781. I've verified that tip still fails, so it's probably another variation the previous fixes don't cover.
cc @ianlancetaylor
Sorry, something went wrong.
Change https://golang.org/cl/174524 mentions this issue: cmd/cgo: fix unexpected semicolon in rewritten line
cmd/cgo: fix unexpected semicolon in rewritten line
a88cb1d
No branches or pull requests
What version of Go are you using (
go version
)?main.go
What did you expect to see?
build success,
but go 1.11.4 is ok.
What did you see instead?
main.go:21:27: syntax error: unexpected semicolon, expecting expression
The text was updated successfully, but these errors were encountered: