]> Cypherpunks repositories - gostls13.git/commit
cmd/cgo: don't strip qualifiers from C void* pointer
authorIan Lance Taylor <iant@golang.org>
Tue, 13 Dec 2016 22:29:57 +0000 (14:29 -0800)
committerIan Lance Taylor <iant@golang.org>
Wed, 14 Dec 2016 00:59:38 +0000 (00:59 +0000)
commit10f3b090270a979dfbbb48be98973feac61dfc91
tree4fbfcf2ba0b581008d741f6ebfb00256fa1e56d8
parent4284edb999716c408c99e9b5dc56734c31e4dcd5
cmd/cgo: don't strip qualifiers from C void* pointer

Now that we try to handle qualifiers correctly (as of CL 33325), don't
strip them from a void* pointer. Otherwise we break a case like "const
void**", as the "const" qualifier is dropped and the resulting
"void**" triggers a warning from the C compiler.

Fixes #18298.

Change-Id: If51df1889b0f6a907715298c152e6d4584747acb
Reviewed-on: https://go-review.googlesource.com/34370
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
misc/cgo/test/issue17537.go
src/cmd/cgo/gcc.go