| |
| |
| |
|
|
| package main |
|
|
| import "C" |
|
|
| |
| func ReturnEmpty() { |
| return |
| } |
|
|
| |
| func ReturnOnlyUint8() (uint8, uint8, uint8) { |
| return 1, 2, 3 |
| } |
|
|
| |
| func ReturnOnlyUint16() (uint16, uint16, uint16) { |
| return 1, 2, 3 |
| } |
|
|
| |
| func ReturnOnlyUint32() (uint32, uint32, uint32) { |
| return 1, 2, 3 |
| } |
|
|
| |
| func ReturnOnlyUint64() (uint64, uint64, uint64) { |
| return 1, 2, 3 |
| } |
|
|
| |
| func ReturnOnlyInt() (int, int, int) { |
| return 1, 2, 3 |
| } |
|
|
| |
| func ReturnOnlyPtr() (*int, *int, *int) { |
| a, b, c := 1, 2, 3 |
| return &a, &b, &c |
| } |
|
|
| |
| func ReturnString() string { |
| return "hello" |
| } |
|
|
| |
| func ReturnByteSlice() []byte { |
| return []byte{1, 2, 3} |
| } |
|
|
| |
| func InputAndReturnUint8(a, b, c uint8) (uint8, uint8, uint8) { |
| return a, b, c |
| } |
|
|
| |
| func MixedTypes(a uint8, b uint16, c uint32, d uint64, e int, f *int) (uint8, uint16, uint32, uint64, int, *int) { |
| return a, b, c, d, e, f |
| } |
|
|