Skip to content

Instantly share code, notes, and snippets.

@tonistiigi
Last active January 28, 2022 20:35
Show Gist options
  • Save tonistiigi/ab6ef71781b7e3c5cabcb71a286a9243 to your computer and use it in GitHub Desktop.
Save tonistiigi/ab6ef71781b7e3c5cabcb71a286a9243 to your computer and use it in GitHub Desktop.
/tmp # CC=gcc go build t.go
/tmp # CC=clang go build t.go
# command-line-arguments
./t.go:11:2: duplicate case _Ciconst_bar (value 1) in switch
previous case at ./t.go:10:2
/tmp #
/tmp #
/tmp # cat t.go
package main
//const int foo = 1;
//const int bar = 1;
import "C"
func main() {
var a C.int
switch a {
case C.foo:
case C.bar:
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment