code: func GoTypeFor(typ cc.Type, name string, types ...map[bg.TypeKey]bg.Template) string {
  	if typ == nil {
  		return "<nil>"
  	}
  	k := typ.Kind()
  	isPtr := typ.Kind() == cc.Ptr
  	if isPtr {
  		k = typ.Element().Kind()
  	}
  	var buf bytes.Buffer
  	for _, t := range types {
  		if s, ok := t[bg.TypeKey{Kind: k, IsPointer: isPtr}]; ok {
  			err := s.Execute(&buf, name)
  			if err != nil {
  				panic(err)
  			}
  			return buf.String()
  		}
  	}
  	s, ok := goTypes[bg.TypeKey{Kind: k, IsPointer: isPtr}]
  	if ok {
  		err := s.Execute(&buf, name)
  		if err != nil {
  			panic(err)
  		}
  		return buf.String()
  	}
  	log.Printf("%v", typ.Tag())
  	panic(fmt.Sprintf("unknown type key: %v %+v", typ, bg.TypeKey{Kind: k, IsPointer: isPtr}))
  }
docs: // GoTypeFor returns a string representation of the given type using a mapping in
  // types. GoTypeFor will panic if no type mapping is found after searching the
  // user-provided types mappings and then the following mapping:
  //  {Kind: cc.Int}:                     "int",
  //  {Kind: cc.Float}:                   "float32",
  //  {Kind: cc.Float, IsPointer: true}:  "[]float32",
  //  {Kind: cc.Double}:                  "float64",
  //  {Kind: cc.Double, IsPointer: true}: "[]float64",
  //  {Kind: cc.Bool}:                    "bool",
  //  {Kind: cc.FloatComplex}:            "complex64",
  //  {Kind: cc.DoubleComplex}:           "complex128",