MCPcopy
hub / github.com/openai/openai-go / continueWithTimeFmt

Function continueWithTimeFmt

internal/encoding/json/time.go:36–41  ·  view source on GitHub ↗

Uses continuation passing style, to add the timefmt option to k

(timefmt string, k encoderFunc)

Source from the content-addressed store, hash-verified

34
35// Uses continuation passing style, to add the timefmt option to k
36func 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
43func timeMarshalEncoder(e *encodeState, v reflect.Value, opts encOpts) bool {
44 tm, ok := v.Interface().(TimeMarshaler)

Callers 1

typeFieldsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…