z_0_filetest.gno

0.35 Kb ยท 23 lines
 1// PKGPATH: gno.land/r/test
 2package test
 3
 4import (
 5	"gno.land/p/nt/avl"
 6)
 7
 8var node *avl.Node
 9
10func init() {
11	node = avl.NewNode("key0", "value0")
12	// node, _ = node.Set("key0", "value0")
13}
14
15func main(cur realm) {
16	var updated bool
17	node, updated = node.Set("key1", "value1")
18	// println(node, updated)
19	println(updated, node.Size())
20}
21
22// Output:
23// false 2