code: func printPackage(pkg *Package) {
  	if len(pkg.Enums) > 0 {
  		logf("loaded %d enums:", len(pkg.Enums))
  		for k, enum := range pkg.Enums {
  			logf(" - enum #%d\t%+v", k, enum)
  		}
  	}
  	if len(pkg.Unions) > 0 {
  		logf("loaded %d unions:", len(pkg.Unions))
  		for k, union := range pkg.Unions {
  			logf(" - union #%d\t%+v", k, union)
  		}
  	}
  	if len(pkg.Types) > 0 {
  		logf("loaded %d types:", len(pkg.Types))
  		for _, typ := range pkg.Types {
  			logf(" - type: %q (%d fields)", typ.Name, len(typ.Fields))
  		}
  	}
  	if len(pkg.Messages) > 0 {
  		logf("loaded %d messages:", len(pkg.Messages))
  		for _, msg := range pkg.Messages {
  			logf(" - message: %q (%d fields)", msg.Name, len(msg.Fields))
  		}
  	}
  	if len(pkg.Services) > 0 {
  		logf("loaded %d services:", len(pkg.Services))
  		for _, svc := range pkg.Services {
  			var info string
  			if svc.Stream {
  				info = "(STREAM)"
  			} else if len(svc.Events) > 0 {
  				info = fmt.Sprintf("(EVENTS: %v)", svc.Events)
  			}
  			logf(" - service: %q -> %q %s", svc.RequestType, svc.ReplyType, info)
  		}
  	}
  }
docs: // printPackage prints all loaded objects for package