func marshalWithMarshalText(t reflect.Type, tag tag) marshaler {
	formSet := formSetter(tag)
	omit := omitter(t, tag)
	return func(v reflect.Value, p *Params) error {
		if omit(v) {
			return nil
		}
		m := v.Addr().Interface().(encodingTextMarshaler)
		data, err := m.MarshalText()
		if err != nil {
			return errgo.Mask(err)
		}
		formSet(tag.name, string(data), p)
		return nil
	}
}
// marshalWithMarshalText returns a marshaler
// that marshals the given type from the given tag
// using its MarshalText method.
marshalWithMarshalText returns a marshaler
that marshals the given type from the given tag
using its MarshalText method.
// marshalWithMarshalText returns a marshaler // that marshals the given type from the given tag // using its MarshalText method .
func marshalWithMarshalText(t reflect.Type, tag tag) marshaler {
	formSet := formSetter(tag)
	omit := omitter(t, tag)
	return func(v reflect.Value, p *Params) error {
		if omit(v) {
			return nil
		}
		m := v.Addr().Interface().(encodingTextMarshaler)
		data, err := m.MarshalText()
		if err != nil {
			return errgo.Mask(err)
		}
		formSet(tag.name, string(data), p)
		return nil
	}
}
func marshalWithMarshalText ( t reflect . Type , tag tag ) marshaler { formSet := formSetter ( tag ) omit := omitter ( t , tag ) return func ( v reflect . Value , p * Params ) error { if omit ( v ) { return nil } m := v . Addr ( ) . Interface ( ) . ( encodingTextMarshaler ) data , err := m . MarshalText ( ) if err != nil { return errgo . Mask ( err ) } formSet ( tag . name , string ( data ) , p ) return nil } }
marshalWithMarshalText returns a marshaler
that marshals the given type from the given tag
using its MarshalText method.
marshalWithMarshalText returns a marshaler that marshals the given type from the given tag using its MarshalText method .