]> Cypherpunks repositories - gostls13.git/commit
cmd/cgo: disable GCC 9 warnings triggered by cgo code
authorIan Lance Taylor <iant@golang.org>
Mon, 28 Jan 2019 20:31:55 +0000 (12:31 -0800)
committerIan Lance Taylor <iant@golang.org>
Wed, 30 Jan 2019 22:25:36 +0000 (22:25 +0000)
commitf2a416b90ac68596ea05b97cefa8c72e7416e98f
treeeccb8a974e8dc406b5b671b4e4ca480b501cd324
parent737695231de878dfdea127de1b995548785e3db0
cmd/cgo: disable GCC 9 warnings triggered by cgo code

GCC 9 has started emitting warnings when taking the address of a field
in a packed struct may cause a misaligned pointer. We use packed
structs in cgo to ensure that our field layout matches the C
compiler's layout. Our pointers are always aligned, so disable the warning

Fixes #29962

Change-Id: I7e290a7cf694a2c2958529e340ebed9fcd62089c
Reviewed-on: https://go-review.googlesource.com/c/159859
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
src/cmd/cgo/out.go