Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/cgo: generate definition for GoSlice #3741

gopherbot opened this issue Jun 15, 2012 · 2 comments


Copy link

commented Jun 15, 2012

by wangxuefu:

Before filing a bug, please check whether it has been fixed since the
latest release. Search the issue tracker and check that you're running the
latest version of Go:

Run "go version" and compare against  If a newer version of Go exists,
install it and retry what you did to reproduce the problem.


What steps will reproduce the problem?
If possible, include a link to a program on
1.  export go function to c, fuction likes this:

func TSlice(s []interface{}) {}

What is the expected output?

go build success

What do you see instead?

go build error

in _cgo_export.h, "extern void TSlice(GoSlice po);" is generated, but GoSlice
not defined.

Which compiler are you using (5g, 6g, 8g, gccgo)?

go build

Which operating system are you using?

linux 64

Which version are you using?  (run 'go version')


Please provide any additional information below.

This comment has been minimized.

Copy link

commented Jun 15, 2012

Comment 1:

Labels changed: added priority-later, cgo, removed priority-triage.

Owner changed to @minux.

Status changed to Accepted.


This comment has been minimized.

Copy link

commented Jun 30, 2012

Comment 2:

This issue was closed by revision 33d2b49.

Status changed to Fixed.

@golang golang locked and limited conversation to collaborators Jun 24, 2016

This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
2 participants
You can’t perform that action at this time.