aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/cgo/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/cmd/cgo/main.go')
-rw-r--r--src/cmd/cgo/main.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/cmd/cgo/main.go b/src/cmd/cgo/main.go
index 2b3e6a0a01..c3c53b35c0 100644
--- a/src/cmd/cgo/main.go
+++ b/src/cmd/cgo/main.go
@@ -394,6 +394,10 @@ func (p *Package) Record(f *File) {
p.Name[k] = v
} else if p.incompleteTypedef(v.Type) {
// Nothing to do.
+ } else if _, ok := nameToC[k]; ok {
+ // Names we predefine may appear inconsistent
+ // if some files typedef them and some don't.
+ // Issue 26743.
} else if !reflect.DeepEqual(p.Name[k], v) {
error_(token.NoPos, "inconsistent definitions for C.%s", fixGo(k))
}