code: func ListExportedFieldsPtrs(val interface{}, predicates ...ExportedPredicate) (
  	fields []*reflect.StructField, valPtrs []interface{}) {
  
  	rVal := reflect.Indirect(reflect.ValueOf(val))
  	valPtrs = []interface{}{}
  	fields = []*reflect.StructField{}
  
  	for i := 0; i < rVal.NumField(); i++ {
  		field := rVal.Field(i)
  		structField := rVal.Type().Field(i)
  		if !FieldExported(&structField, predicates...) {
  			continue
  		}
  
  		switch field.Kind() {
  		case reflect.Ptr, reflect.Interface:
  			if field.IsNil() {
  				p := reflect.New(field.Type().Elem())
  				field.Set(p)
  				valPtrs = append(valPtrs, p.Interface())
  			} else {
  				valPtrs = append(valPtrs, field.Interface())
  			}
  		case reflect.Slice, reflect.Chan, reflect.Map:
  			if field.IsNil() {
  				p := reflect.New(field.Type())
  				field.Set(p.Elem())
  				valPtrs = append(valPtrs, field.Addr().Interface())
  			} else {
  				valPtrs = append(valPtrs, field.Interface())
  			}
  		default:
  			if field.CanAddr() {
  				valPtrs = append(valPtrs, field.Addr().Interface())
  			} else if field.IsValid() {
  				valPtrs = append(valPtrs, field.Interface())
  			} else {
  				panic("invalid field")
  			}
  		}
  
  		fields = append(fields, &structField)
  	}
  
  	return fields, valPtrs
  }
docs: // ListExportedFieldsPtrs iterates struct fields and return slice of pointers to field values