15 lines
201 B
Go
15 lines
201 B
Go
|
package cgo
|
||
|
|
||
|
// #include "cgo.h"
|
||
|
import "C"
|
||
|
|
||
|
func Add(x, y int64) int64 {
|
||
|
return int64(C.add(C.int64_t(x), C.int64_t(y)))
|
||
|
}
|
||
|
|
||
|
//export AddInternal
|
||
|
func AddInternal(x, y int64) int64 {
|
||
|
|
||
|
return x + y
|
||
|
}
|