code: func (g *Generator) safeName(t reflect.Type) string {
  	name := t.PkgPath()
  	if t.Name() == "" {
  		name += "anonymous"
  	} else {
  		name += "." + t.Name()
  	}
  
  	parts := []string{}
  	part := []rune{}
  	for _, c := range name {
  		if unicode.IsLetter(c) || unicode.IsDigit(c) {
  			part = append(part, c)
  		} else if len(part) > 0 {
  			parts = append(parts, string(part))
  			part = []rune{}
  		}
  	}
  	return joinFunctionNameParts(false, parts...)
  }
docs: // safeName escapes unsafe characters in pkg/type name and returns a string that can be used
  // in encoder/decoder names for the type.