1
0
mirror of https://github.com/golang/go synced 2024-11-13 20:40:31 -07:00
go/misc/cgo/test/testdata/issue43639/a.go
Hans df9c5d8f5d cmd/cgo: fix unused parameter warnings in generated _cgo_main.c
Applying -Werror compiler option to request warnings is an usual
way to discover potential errors. Go user may put a cgo directive
in preamble: `// #cgo CFLAGS: -Werror=unused-parameter`.

However, the directive also takes effect on the cgo generated files.
I cleaned _cgo_main.c to help Go user only concentrate on warnings
of their own file.

Fixes #43639

Change-Id: I9112f02ae5226f2fc87a8650d19faee59cddd588
GitHub-Last-Rev: f09d172f97
GitHub-Pull-Request: golang/go#46358
Reviewed-on: https://go-review.googlesource.com/c/go/+/322232
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Trust: Bryan C. Mills <bcmills@google.com>
2021-08-16 23:03:03 +00:00

9 lines
224 B
Go

// Copyright 2021 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package issue43639
// #cgo CFLAGS: -W -Wall -Werror
import "C"