aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2014-11-10 08:12:43 -0800
committerIan Lance Taylor <iant@golang.org>2014-11-10 08:12:43 -0800
commit63fe9efb90a076422c67d34426b0076c2af1d8ab (patch)
treef3223e93b9c565c47b0dc6d000893f83a2342f35
parentcea69d687732be20e0ca245b162b59eba26fff54 (diff)
downloadgo-63fe9efb90a076422c67d34426b0076c2af1d8ab.tar.gz
go-63fe9efb90a076422c67d34426b0076c2af1d8ab.zip
cmd/cgo: tweak doc to not show example of passing Go pointer
LGTM=rsc R=rsc CC=golang-codereviews https://golang.org/cl/171360043
-rw-r--r--src/cmd/cgo/doc.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cmd/cgo/doc.go b/src/cmd/cgo/doc.go
index 69c7ce893c..6179c7afd1 100644
--- a/src/cmd/cgo/doc.go
+++ b/src/cmd/cgo/doc.go
@@ -152,7 +152,7 @@ In C, a function argument written as a fixed size array
actually requires a pointer to the first element of the array.
C compilers are aware of this calling convention and adjust
the call accordingly, but Go cannot. In Go, you must pass
-the pointer to the first element explicitly: C.f(&x[0]).
+the pointer to the first element explicitly: C.f(&C.x[0]).
A few special functions convert between Go and C types
by making copies of the data. In pseudo-Go definitions: