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: bool alignment/padding issue. #4417

Closed
gopherbot opened this issue Nov 21, 2012 · 2 comments

Comments

@gopherbot
Copy link

commented Nov 21, 2012

by shane.hanna:

I'm getting other values when passing bools to C. I showed the blokes on #go-nuts and
multiple people confirmed that it's some sort of alignment or padding issue.

What steps will reproduce the problem?
http://play.golang.org/p/8mdSR5CVrsi

What is the expected output?
0 or 1

What do you see instead?
171

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


Which operating system are you using?
linux (mint) amd64

Which version are you using?  (run 'go version')
go1.0.3

Please provide any additional information below.

If you stick another argument after the bool you get the other argument.
http://play.golang.org/p/chEi4dC37m
@davecheney

This comment has been minimized.

Copy link
Contributor

commented Nov 21, 2012

Comment 1:

Correct play link is: http://play.golang.org/p/8mdSR5CVrs
@ianlancetaylor

This comment has been minimized.

Copy link
Contributor

commented Nov 21, 2012

Comment 2:

This issue was closed by revision dd01e92.

Status changed to Fixed.

@rsc rsc added this to the Go1.1 milestone Apr 14, 2015

@rsc rsc removed the go1.1 label Apr 14, 2015

@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.
Projects
None yet
4 participants
You can’t perform that action at this time.