jitdec
v1.15.5
github.com/bytedance/sonic/internal/decoder/jitdec
Documentation
pkg.go.dev ↗Functions
Decode
func Decode(s *string, i *int, f uint64, val interface{}) error
Decode parses the JSON-encoded data from current position and stores the result in the value pointed to by val.
Pretouch
func Pretouch(vt reflect.Type, opts ...option.CompileOption) error
Pretouch compiles vt ahead-of-time to avoid JIT compilation on-the-fly, in order to reduce the first-hit latency.
Opts are the compile options, for example, "option.WithCompileRecursiveDepth" is a compile option to set the depth of recursive compile for the nested struct type.
PretouchMany
func PretouchMany(vts []reflect.Type, opts ...option.CompileOption) error
PretouchMany compiles all vts ahead-of-time to avoid JIT compilation on-the-fly, in order to reduce the first-hit latency.
Types
MismatchQuotedError
type MismatchQuotedError struct{}
used to distinguish between MismatchQuoted and other MismatchedTyped errors, see issue #670 and #716
MismatchQuotedError.Error
func (*MismatchQuotedError) Error() string
MismatchTypeError
type MismatchTypeError = errors.MismatchTypeError
SyntaxError
type SyntaxError = errors.SyntaxError