func Decode(out interface{}, v *MrbValue) error {
	val := reflect.ValueOf(out)
	if val.Kind() != reflect.Ptr {
		return errors.New("result must be a pointer")
	}
	var d decoder
	return d.decode("root", v, val.Elem())
}
Decode converts the Ruby value to a Go value.

The Decode process may call Ruby code and may generate Ruby garbage,
but it collects all of its own garbage. You don't need to GC around this.

See the tests (decode_test.go) for detailed and specific examples of
how this function decodes. Basic examples are also available here and
in the README.

For primitives, the decoding process is likely what you expect. For Ruby,
this is booleans, strings, fixnums, and floats. These map directly to
effectively equivalent Go types: bool, string, int, float64.
Hash and Arrays can map directly to maps and slices in Go, and Decode
will handle this as you expect.

The only remaining data type in Go is a struct. A struct in Go can map
to any object in Ruby. If the data in Ruby is a hash, then the struct keys
will map directly to the hash keys. If the data in Ruby is an object, then
one of two things will be done. First: if the object responds to the
`to_gomruby` function, then this will be called and the resulting value
is expected to be a Hash and will be used to decode into the struct. If
the object does NOT respond to that function, then any struct fields will
invoke the corresponding Ruby method to attain the value.

Note that with structs you can use the `mruby` tag to specify the
Hash key or method name to call. Example:

type Foo struct {
Field string `mruby:"read_field"`
}
package mruby
import (
	"errors"
	"fmt"
	"reflect"
	"sort"
	"strconv"
	"strings"
)
const tagName = "mruby"