cmd/cgo: can't pass kCFRunLoopDefaultMode as CFRunLoopMode #24531
Labels
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
OS-Darwin
Milestone
What version of Go are you using (
go version
)?go version go1.10 darwin/amd64
and
go version devel +dc3a92edaa Mon Mar 26 19:42:08 2018 +0000 darwin/amd64
Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?What did you do?
Trying to compile CGO code on darwin that makes calls to C functions, it would compile correctly on go 1.9.2 but now fails to build on go 1.10
What did you expect to see?
A successful build
What did you see instead?
More information
I understand in go 1.10 there where changes made to how CGO is handled for darwin platforms, I did update some other parts of my code to comply with the new nil variable setting (
val =0
vsval = nil
) but this error doesn't seem to make sense.The function being called is CFRunLoopRemoveSource who's third parameter accepts a type of CFRunLoopMode which is just a typedef of CFStringRef.
For the third parameter I am passing kCFRunLoopDefaultMode which should comply with the type matching as it has a type of CFRunLoopMode.
Example Code
https://gist.github.com/LiamHaworth/d50ce9167fe0377cd20d6585d77a70b4
The text was updated successfully, but these errors were encountered: