mirror of
https://github.com/QuilibriumNetwork/ceremonyclient.git
synced 2026-02-21 10:27:26 +08:00
* v2.1.0 [omit consensus and adjacent] - this commit will be amended with the full release after the file copy is complete * 2.1.0 main node rollup
25 lines
257 B
Go
25 lines
257 B
Go
// -*- go -*-
|
|
|
|
package main
|
|
|
|
type Foo struct {
|
|
A int32
|
|
B int32
|
|
}
|
|
|
|
func Set(ptr *int32, val int32) {
|
|
*ptr = val
|
|
}
|
|
|
|
var f Foo
|
|
|
|
// @Test 0 0 = 0
|
|
// @Test 1 2 = 3
|
|
// @Test 7 4 = 11
|
|
func main(a, b int32) int {
|
|
Set(&f.A, a)
|
|
Set(&f.B, b)
|
|
|
|
return f.A + f.B
|
|
}
|