Uses continuation passing style, to add the timefmt option to k
(timefmt string, k encoderFunc)
| 34 | |
| 35 | // Uses continuation passing style, to add the timefmt option to k |
| 36 | func continueWithTimeFmt(timefmt string, k encoderFunc) encoderFunc { |
| 37 | return func(e *encodeState, v reflect.Value, opts encOpts) { |
| 38 | opts.timefmt = timefmt |
| 39 | k(e, v, opts) |
| 40 | } |
| 41 | } |
| 42 | |
| 43 | func timeMarshalEncoder(e *encodeState, v reflect.Value, opts encOpts) bool { |
| 44 | tm, ok := v.Interface().(TimeMarshaler) |
no outgoing calls
no test coverage detected
searching dependent graphs…