From 61e533dca2b19ee4071322f9cb8bf87d5182c71f Mon Sep 17 00:00:00 2001 From: Masaaki Goshima Date: Sun, 31 Jan 2021 22:45:59 +0900 Subject: [PATCH 1/6] Refactor encoder --- encode.go | 335 ++-- encode_compile.go | 431 +++-- encode_context.go | 11 +- encode_opcode.go | 2 +- encode_vm.go | 2098 +++++++++++------------ encode_vm_escaped.go | 2049 +++++++++++------------ encode_vm_escaped_indent.go | 3120 +++++++++++++++++------------------ encode_vm_indent.go | 3120 +++++++++++++++++------------------ json.go | 61 +- option.go | 9 +- 10 files changed, 5626 insertions(+), 5610 deletions(-) diff --git a/encode.go b/encode.go index a48c4c3..a9fc6c7 100644 --- a/encode.go +++ b/encode.go @@ -2,154 +2,58 @@ package json import ( "bytes" - "encoding" "encoding/base64" - "fmt" "io" "math" - "reflect" "strconv" "sync" - "sync/atomic" "unsafe" ) // An Encoder writes JSON values to an output stream. type Encoder struct { w io.Writer - ctx *encodeRuntimeContext - ptr unsafe.Pointer - buf []byte enabledIndent bool enabledHTMLEscape bool - unorderedMap bool - baseIndent int - prefix []byte - indentStr []byte -} - -type compiledCode struct { - code *opcode - linked bool // whether recursive code already have linked - curLen uintptr - nextLen uintptr + prefix string + indentStr string } const ( - bufSize = 1024 - maxAcceptableTypeAddrRange = 1024 * 1024 * 2 // 2 Mib + bufSize = 1024 ) +type EncodeOption int + const ( - opCodeEscapedType = iota - opCodeEscapedIndentType - opCodeNoEscapeType - opCodeNoEscapeIndentType + EncodeOptionHTMLEscape EncodeOption = 1 << iota + EncodeOptionIndent + EncodeOptionUnorderedMap ) -type opcodeSet struct { - code *opcode - codeLength int -} - -func loadOpcodeMap() map[uintptr]*opcodeSet { - p := atomic.LoadPointer(&cachedOpcode) - return *(*map[uintptr]*opcodeSet)(unsafe.Pointer(&p)) -} - -func storeOpcodeSet(typ uintptr, set *opcodeSet, m map[uintptr]*opcodeSet) { - newOpcodeMap := make(map[uintptr]*opcodeSet, len(m)+1) - newOpcodeMap[typ] = set - - for k, v := range m { - newOpcodeMap[k] = v - } - - atomic.StorePointer(&cachedOpcode, *(*unsafe.Pointer)(unsafe.Pointer(&newOpcodeMap))) -} - var ( - encPool sync.Pool - codePool sync.Pool - cachedOpcode unsafe.Pointer // map[uintptr]*opcodeSet - marshalJSONType reflect.Type - marshalTextType reflect.Type - baseTypeAddr uintptr - cachedOpcodeSets []*opcodeSet -) - -//go:linkname typelinks reflect.typelinks -func typelinks() ([]unsafe.Pointer, [][]int32) - -//go:linkname rtypeOff reflect.rtypeOff -func rtypeOff(unsafe.Pointer, int32) unsafe.Pointer - -func setupOpcodeSets() error { - sections, offsets := typelinks() - if len(sections) != 1 { - return fmt.Errorf("failed to get sections") - } - if len(offsets) != 1 { - return fmt.Errorf("failed to get offsets") - } - section := sections[0] - offset := offsets[0] - var ( - min uintptr = uintptr(^uint(0)) - max uintptr = 0 - ) - for i := 0; i < len(offset); i++ { - addr := uintptr(rtypeOff(section, offset[i])) - if min > addr { - min = addr - } - if max < addr { - max = addr - } - } - addrRange := uintptr(max) - uintptr(min) - if addrRange == 0 { - return fmt.Errorf("failed to get address range of types") - } - if addrRange > maxAcceptableTypeAddrRange { - return fmt.Errorf("too big address range %d", addrRange) - } - cachedOpcodeSets = make([]*opcodeSet, addrRange) - baseTypeAddr = min - return nil -} - -func init() { - encPool = sync.Pool{ + encRuntimeContextPool = sync.Pool{ New: func() interface{} { - return &Encoder{ - ctx: &encodeRuntimeContext{ - ptrs: make([]uintptr, 128), - keepRefs: make([]unsafe.Pointer, 0, 8), - }, - buf: make([]byte, 0, bufSize), + return &encodeRuntimeContext{ + buf: make([]byte, 0, bufSize), + ptrs: make([]uintptr, 128), + keepRefs: make([]unsafe.Pointer, 0, 8), } }, } - marshalJSONType = reflect.TypeOf((*Marshaler)(nil)).Elem() - marshalTextType = reflect.TypeOf((*encoding.TextMarshaler)(nil)).Elem() - if err := setupOpcodeSets(); err != nil { - // fallback to slow path - } +) + +func takeEncodeRuntimeContext() *encodeRuntimeContext { + return encRuntimeContextPool.Get().(*encodeRuntimeContext) +} + +func releaseEncodeRuntimeContext(ctx *encodeRuntimeContext) { + encRuntimeContextPool.Put(ctx) } // NewEncoder returns a new encoder that writes to w. func NewEncoder(w io.Writer) *Encoder { - enc := encPool.Get().(*Encoder) - enc.w = w - enc.reset() - return enc -} - -func newEncoder() *Encoder { - enc := encPool.Get().(*Encoder) - enc.reset() - return enc + return &Encoder{w: w, enabledHTMLEscape: true} } // Encode writes the JSON encoding of v to the stream, followed by a newline character. @@ -160,15 +64,23 @@ func (e *Encoder) Encode(v interface{}) error { } // EncodeWithOption call Encode with EncodeOption. -func (e *Encoder) EncodeWithOption(v interface{}, opts ...EncodeOption) error { - for _, opt := range opts { - if err := opt(e); err != nil { - return err - } +func (e *Encoder) EncodeWithOption(v interface{}, optFuncs ...EncodeOptionFunc) error { + var opt EncodeOption + if e.enabledHTMLEscape { + opt |= EncodeOptionHTMLEscape + } + for _, optFunc := range optFuncs { + opt = optFunc(opt) + } + var ( + buf []byte + err error + ) + if e.enabledIndent { + buf, err = encodeIndentWithOpt(v, e.prefix, e.indentStr, opt) + } else { + buf, err = encodeWithOpt(v, opt) } - header := (*interfaceHeader)(unsafe.Pointer(&v)) - e.ptr = header.ptr - buf, err := e.encode(header, v == nil) if err != nil { return err } @@ -181,7 +93,6 @@ func (e *Encoder) EncodeWithOption(v interface{}, opts ...EncodeOption) error { if _, err := e.w.Write(buf); err != nil { return err } - e.buf = buf[:0] return nil } @@ -200,40 +111,17 @@ func (e *Encoder) SetIndent(prefix, indent string) { e.enabledIndent = false return } - e.prefix = []byte(prefix) - e.indentStr = []byte(indent) + e.prefix = prefix + e.indentStr = indent e.enabledIndent = true } -func (e *Encoder) release() { - e.w = nil - encPool.Put(e) -} - -func (e *Encoder) reset() { - e.baseIndent = 0 - e.enabledHTMLEscape = true - e.enabledIndent = false - e.unorderedMap = false -} - -func (e *Encoder) encodeForMarshal(header *interfaceHeader, isNil bool) ([]byte, error) { - buf, err := e.encode(header, isNil) +func marshal(v interface{}, opt EncodeOption) ([]byte, error) { + buf, err := encodeWithOpt(v, EncodeOptionHTMLEscape) if err != nil { return nil, err } - e.buf = buf - - if e.enabledIndent { - // this line's description is the below. - buf = buf[:len(buf)-2] - - copied := make([]byte, len(buf)) - copy(copied, buf) - return copied, nil - } - // this line exists to escape call of `runtime.makeslicecopy` . // if use `make([]byte, len(buf)-1)` and `copy(copied, buf)`, // dst buffer size and src buffer size are differrent. @@ -245,95 +133,98 @@ func (e *Encoder) encodeForMarshal(header *interfaceHeader, isNil bool) ([]byte, return copied, nil } -func (e *Encoder) encode(header *interfaceHeader, isNil bool) ([]byte, error) { - b := e.buf[:0] - if isNil { +func marshalIndent(v interface{}, prefix, indent string, opt EncodeOption) ([]byte, error) { + buf, err := encodeIndentWithOpt(v, prefix, indent, EncodeOptionHTMLEscape) + if err != nil { + return nil, err + } + buf = buf[:len(buf)-2] + + copied := make([]byte, len(buf)) + copy(copied, buf) + return copied, nil +} + +func encodeWithOpt(v interface{}, opt EncodeOption) ([]byte, error) { + ctx := takeEncodeRuntimeContext() + b := ctx.buf[:0] + if v == nil { b = encodeNull(b) - if e.enabledIndent { - b = encodeIndentComma(b) - } else { - b = encodeComma(b) - } + b = encodeComma(b) return b, nil } + header := (*interfaceHeader)(unsafe.Pointer(&v)) typ := header.typ typeptr := uintptr(unsafe.Pointer(typ)) - codeSet, err := e.compileToGetCodeSet(typeptr) + codeSet, err := encodeCompileToGetCodeSet(typeptr) if err != nil { return nil, err } - ctx := e.ctx p := uintptr(header.ptr) ctx.init(p, codeSet.codeLength) - if e.enabledIndent { - if e.enabledHTMLEscape { - return e.runEscapedIndent(ctx, b, codeSet) - } else { - return e.runIndent(ctx, b, codeSet) - } + buf, err := encodeRunCode(ctx, b, codeSet, opt) + + ctx.keepRefs = append(ctx.keepRefs, header.ptr) + + if err != nil { + releaseEncodeRuntimeContext(ctx) + return nil, err } - if e.enabledHTMLEscape { - return e.runEscaped(ctx, b, codeSet) - } - return e.run(ctx, b, codeSet) + + ctx.buf = buf + releaseEncodeRuntimeContext(ctx) + return buf, nil } -func (e *Encoder) compileToGetCodeSet(typeptr uintptr) (*opcodeSet, error) { - if cachedOpcodeSets == nil { - return e.compileToGetCodeSetSlowPath(typeptr) - } - if codeSet := cachedOpcodeSets[typeptr-baseTypeAddr]; codeSet != nil { - return codeSet, nil +func encodeIndentWithOpt(v interface{}, prefix, indent string, opt EncodeOption) ([]byte, error) { + ctx := takeEncodeRuntimeContext() + b := ctx.buf[:0] + if v == nil { + b = encodeNull(b) + b = encodeIndentComma(b) + return b, nil } + header := (*interfaceHeader)(unsafe.Pointer(&v)) + typ := header.typ - // noescape trick for header.typ ( reflect.*rtype ) - copiedType := *(**rtype)(unsafe.Pointer(&typeptr)) - - code, err := e.compileHead(&encodeCompileContext{ - typ: copiedType, - root: true, - structTypeToCompiledCode: map[uintptr]*compiledCode{}, - }) + typeptr := uintptr(unsafe.Pointer(typ)) + codeSet, err := encodeCompileToGetCodeSet(typeptr) if err != nil { return nil, err } - code = copyOpcode(code) - codeLength := code.totalLength() - codeSet := &opcodeSet{ - code: code, - codeLength: codeLength, - } - cachedOpcodeSets[int(typeptr-baseTypeAddr)] = codeSet - return codeSet, nil -} -func (e *Encoder) compileToGetCodeSetSlowPath(typeptr uintptr) (*opcodeSet, error) { - opcodeMap := loadOpcodeMap() - if codeSet, exists := opcodeMap[typeptr]; exists { - return codeSet, nil - } + p := uintptr(header.ptr) + ctx.init(p, codeSet.codeLength) + buf, err := encodeRunIndentCode(ctx, b, codeSet, prefix, indent, opt) - // noescape trick for header.typ ( reflect.*rtype ) - copiedType := *(**rtype)(unsafe.Pointer(&typeptr)) + ctx.keepRefs = append(ctx.keepRefs, header.ptr) - code, err := e.compileHead(&encodeCompileContext{ - typ: copiedType, - root: true, - structTypeToCompiledCode: map[uintptr]*compiledCode{}, - }) if err != nil { + releaseEncodeRuntimeContext(ctx) return nil, err } - code = copyOpcode(code) - codeLength := code.totalLength() - codeSet := &opcodeSet{ - code: code, - codeLength: codeLength, + + ctx.buf = buf + releaseEncodeRuntimeContext(ctx) + return buf, nil +} + +func encodeRunCode(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, opt EncodeOption) ([]byte, error) { + if (opt & EncodeOptionHTMLEscape) != 0 { + return encodeRunEscaped(ctx, b, codeSet, opt) } - storeOpcodeSet(typeptr, codeSet, opcodeMap) - return codeSet, nil + return encodeRun(ctx, b, codeSet, opt) +} + +func encodeRunIndentCode(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, prefix, indent string, opt EncodeOption) ([]byte, error) { + ctx.prefix = []byte(prefix) + ctx.indentStr = []byte(indent) + if (opt & EncodeOptionHTMLEscape) != 0 { + return encodeRunEscapedIndent(ctx, b, codeSet, opt) + } + return encodeRunIndent(ctx, b, codeSet, opt) } func encodeFloat32(b []byte, v float32) []byte { @@ -389,10 +280,10 @@ func appendStructEnd(b []byte) []byte { return append(b, '}', ',') } -func (e *Encoder) appendStructEndIndent(b []byte, indent int) []byte { +func appendStructEndIndent(ctx *encodeRuntimeContext, b []byte, indent int) []byte { b = append(b, '\n') - b = append(b, e.prefix...) - b = append(b, bytes.Repeat(e.indentStr, e.baseIndent+indent)...) + b = append(b, ctx.prefix...) + b = append(b, bytes.Repeat(ctx.indentStr, ctx.baseIndent+indent)...) return append(b, '}', ',', '\n') } @@ -411,7 +302,7 @@ func encodeByteSlice(b []byte, src []byte) []byte { return append(append(b, buf...), '"') } -func (e *Encoder) encodeIndent(b []byte, indent int) []byte { - b = append(b, e.prefix...) - return append(b, bytes.Repeat(e.indentStr, e.baseIndent+indent)...) +func encodeIndent(ctx *encodeRuntimeContext, b []byte, indent int) []byte { + b = append(b, ctx.prefix...) + return append(b, bytes.Repeat(ctx.indentStr, ctx.baseIndent+indent)...) } diff --git a/encode_compile.go b/encode_compile.go index 1bfb3d3..04e256c 100644 --- a/encode_compile.go +++ b/encode_compile.go @@ -1,23 +1,178 @@ package json import ( + "encoding" "fmt" "reflect" "strings" + "sync/atomic" "unsafe" ) -func (e *Encoder) compileHead(ctx *encodeCompileContext) (*opcode, error) { +type compiledCode struct { + code *opcode + linked bool // whether recursive code already have linked + curLen uintptr + nextLen uintptr +} + +type opcodeSet struct { + code *opcode + codeLength int +} + +var ( + marshalJSONType = reflect.TypeOf((*Marshaler)(nil)).Elem() + marshalTextType = reflect.TypeOf((*encoding.TextMarshaler)(nil)).Elem() + cachedOpcode unsafe.Pointer // map[uintptr]*opcodeSet + baseTypeAddr uintptr + cachedOpcodeSets []*opcodeSet +) + +const ( + maxAcceptableTypeAddrRange = 1024 * 1024 * 2 // 2 Mib +) + +//go:linkname typelinks reflect.typelinks +func typelinks() ([]unsafe.Pointer, [][]int32) + +//go:linkname rtypeOff reflect.rtypeOff +func rtypeOff(unsafe.Pointer, int32) unsafe.Pointer + +func setupOpcodeSets() error { + sections, offsets := typelinks() + if len(sections) != 1 { + return fmt.Errorf("failed to get sections") + } + if len(offsets) != 1 { + return fmt.Errorf("failed to get offsets") + } + section := sections[0] + offset := offsets[0] + var ( + min uintptr = uintptr(^uint(0)) + max uintptr = 0 + ) + for i := 0; i < len(offset); i++ { + typ := (*rtype)(rtypeOff(section, offset[i])) + addr := uintptr(unsafe.Pointer(typ)) + if min > addr { + min = addr + } + if max < addr { + max = addr + } + if typ.Kind() == reflect.Ptr { + addr = uintptr(unsafe.Pointer(typ.Elem())) + if min > addr { + min = addr + } + if max < addr { + max = addr + } + } + } + addrRange := uintptr(max) - uintptr(min) + if addrRange == 0 { + return fmt.Errorf("failed to get address range of types") + } + if addrRange > maxAcceptableTypeAddrRange { + return fmt.Errorf("too big address range %d", addrRange) + } + cachedOpcodeSets = make([]*opcodeSet, addrRange) + baseTypeAddr = min + return nil +} + +func init() { + if err := setupOpcodeSets(); err != nil { + // fallback to slow path + } +} + +func encodeCompileToGetCodeSet(typeptr uintptr) (*opcodeSet, error) { + if cachedOpcodeSets == nil { + return encodeCompileToGetCodeSetSlowPath(typeptr) + } + if codeSet := cachedOpcodeSets[typeptr-baseTypeAddr]; codeSet != nil { + return codeSet, nil + } + + // noescape trick for header.typ ( reflect.*rtype ) + copiedType := *(**rtype)(unsafe.Pointer(&typeptr)) + + code, err := encodeCompileHead(&encodeCompileContext{ + typ: copiedType, + root: true, + structTypeToCompiledCode: map[uintptr]*compiledCode{}, + }) + if err != nil { + return nil, err + } + code = copyOpcode(code) + codeLength := code.totalLength() + codeSet := &opcodeSet{ + code: code, + codeLength: codeLength, + } + cachedOpcodeSets[int(typeptr-baseTypeAddr)] = codeSet + return codeSet, nil +} + +func encodeCompileToGetCodeSetSlowPath(typeptr uintptr) (*opcodeSet, error) { + opcodeMap := loadOpcodeMap() + if codeSet, exists := opcodeMap[typeptr]; exists { + return codeSet, nil + } + + // noescape trick for header.typ ( reflect.*rtype ) + copiedType := *(**rtype)(unsafe.Pointer(&typeptr)) + + code, err := encodeCompileHead(&encodeCompileContext{ + typ: copiedType, + root: true, + structTypeToCompiledCode: map[uintptr]*compiledCode{}, + }) + if err != nil { + return nil, err + } + code = copyOpcode(code) + codeLength := code.totalLength() + codeSet := &opcodeSet{ + code: code, + codeLength: codeLength, + } + storeOpcodeSet(typeptr, codeSet, opcodeMap) + return codeSet, nil +} + +func loadOpcodeMap() map[uintptr]*opcodeSet { + p := atomic.LoadPointer(&cachedOpcode) + return *(*map[uintptr]*opcodeSet)(unsafe.Pointer(&p)) +} + +func storeOpcodeSet(typ uintptr, set *opcodeSet, m map[uintptr]*opcodeSet) { + newOpcodeMap := make(map[uintptr]*opcodeSet, len(m)+1) + newOpcodeMap[typ] = set + + for k, v := range m { + newOpcodeMap[k] = v + } + + atomic.StorePointer(&cachedOpcode, *(*unsafe.Pointer)(unsafe.Pointer(&newOpcodeMap))) +} + +func encodeCompileHead(ctx *encodeCompileContext) (*opcode, error) { typ := ctx.typ switch { case typ.Implements(marshalJSONType): - return e.compileMarshalJSON(ctx) + return encodeCompileMarshalJSON(ctx) case rtype_ptrTo(typ).Implements(marshalJSONType): - return e.compileMarshalJSONPtr(ctx) + return encodeCompileMarshalJSONPtr(ctx) case typ.Implements(marshalTextType): - return e.compileMarshalText(ctx) + return encodeCompileMarshalText(ctx) case rtype_ptrTo(typ).Implements(marshalTextType): - return e.compileMarshalTextPtr(ctx) + return encodeCompileMarshalTextPtr(ctx) } isPtr := false orgType := typ @@ -26,32 +181,32 @@ func (e *Encoder) compileHead(ctx *encodeCompileContext) (*opcode, error) { isPtr = true } if typ.Kind() == reflect.Map { - return e.compileMap(ctx.withType(typ), isPtr) + return encodeCompileMap(ctx.withType(typ), isPtr) } else if typ.Kind() == reflect.Struct { - code, err := e.compileStruct(ctx.withType(typ), isPtr) + code, err := encodeCompileStruct(ctx.withType(typ), isPtr) if err != nil { return nil, err } - e.convertHeadOnlyCode(code, isPtr) - e.optimizeStructEnd(code) - e.linkRecursiveCode(code) + encodeConvertHeadOnlyCode(code, isPtr) + encodeOptimizeStructEnd(code) + encodeLinkRecursiveCode(code) return code, nil } else if isPtr && typ.Implements(marshalTextType) { typ = orgType } else if isPtr && typ.Implements(marshalJSONType) { typ = orgType } - code, err := e.compile(ctx.withType(typ)) + code, err := encodeCompile(ctx.withType(typ)) if err != nil { return nil, err } - e.convertHeadOnlyCode(code, isPtr) - e.optimizeStructEnd(code) - e.linkRecursiveCode(code) + encodeConvertHeadOnlyCode(code, isPtr) + encodeOptimizeStructEnd(code) + encodeLinkRecursiveCode(code) return code, nil } -func (e *Encoder) linkRecursiveCode(c *opcode) { +func encodeLinkRecursiveCode(c *opcode) { for code := c; code.op != opEnd && code.op != opStructFieldRecursiveEnd; { switch code.op { case opStructFieldRecursive, @@ -82,7 +237,7 @@ func (e *Encoder) linkRecursiveCode(c *opcode) { code.jmp.nextLen = nextTotalLength code.jmp.linked = true - e.linkRecursiveCode(code.jmp.code) + encodeLinkRecursiveCode(code.jmp.code) code = code.next continue } @@ -95,7 +250,7 @@ func (e *Encoder) linkRecursiveCode(c *opcode) { } } -func (e *Encoder) optimizeStructEnd(c *opcode) { +func encodeOptimizeStructEnd(c *opcode) { for code := c; code.op != opEnd; { if code.op == opStructFieldRecursive { // ignore if exists recursive operation @@ -136,7 +291,7 @@ func (e *Encoder) optimizeStructEnd(c *opcode) { } } -func (e *Encoder) convertHeadOnlyCode(c *opcode, isPtrHead bool) { +func encodeConvertHeadOnlyCode(c *opcode, isPtrHead bool) { if c.nextField == nil { return } @@ -145,19 +300,19 @@ func (e *Encoder) convertHeadOnlyCode(c *opcode, isPtrHead bool) { } switch c.op { case opStructFieldHead: - e.convertHeadOnlyCode(c.next, false) + encodeConvertHeadOnlyCode(c.next, false) if !strings.Contains(c.next.op.String(), "Only") { return } c.op = opStructFieldHeadOnly case opStructFieldHeadOmitEmpty: - e.convertHeadOnlyCode(c.next, false) + encodeConvertHeadOnlyCode(c.next, false) if !strings.Contains(c.next.op.String(), "Only") { return } c.op = opStructFieldHeadOmitEmptyOnly case opStructFieldHeadStringTag: - e.convertHeadOnlyCode(c.next, false) + encodeConvertHeadOnlyCode(c.next, false) if !strings.Contains(c.next.op.String(), "Only") { return } @@ -185,7 +340,7 @@ func (e *Encoder) convertHeadOnlyCode(c *opcode, isPtrHead bool) { } } -func (e *Encoder) implementsMarshaler(typ *rtype) bool { +func encodeImplementsMarshaler(typ *rtype) bool { switch { case typ.Implements(marshalJSONType): return true @@ -199,115 +354,115 @@ func (e *Encoder) implementsMarshaler(typ *rtype) bool { return false } -func (e *Encoder) compile(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompile(ctx *encodeCompileContext) (*opcode, error) { typ := ctx.typ switch { case typ.Implements(marshalJSONType): - return e.compileMarshalJSON(ctx) + return encodeCompileMarshalJSON(ctx) case rtype_ptrTo(typ).Implements(marshalJSONType): - return e.compileMarshalJSONPtr(ctx) + return encodeCompileMarshalJSONPtr(ctx) case typ.Implements(marshalTextType): - return e.compileMarshalText(ctx) + return encodeCompileMarshalText(ctx) case rtype_ptrTo(typ).Implements(marshalTextType): - return e.compileMarshalTextPtr(ctx) + return encodeCompileMarshalTextPtr(ctx) } switch typ.Kind() { case reflect.Ptr: - return e.compilePtr(ctx) + return encodeCompilePtr(ctx) case reflect.Slice: elem := typ.Elem() - if !e.implementsMarshaler(elem) && elem.Kind() == reflect.Uint8 { - return e.compileBytes(ctx) + if !encodeImplementsMarshaler(elem) && elem.Kind() == reflect.Uint8 { + return encodeCompileBytes(ctx) } - return e.compileSlice(ctx) + return encodeCompileSlice(ctx) case reflect.Array: - return e.compileArray(ctx) + return encodeCompileArray(ctx) case reflect.Map: - return e.compileMap(ctx, true) + return encodeCompileMap(ctx, true) case reflect.Struct: - return e.compileStruct(ctx, false) + return encodeCompileStruct(ctx, false) case reflect.Interface: - return e.compileInterface(ctx) + return encodeCompileInterface(ctx) case reflect.Int: - return e.compileInt(ctx) + return encodeCompileInt(ctx) case reflect.Int8: - return e.compileInt8(ctx) + return encodeCompileInt8(ctx) case reflect.Int16: - return e.compileInt16(ctx) + return encodeCompileInt16(ctx) case reflect.Int32: - return e.compileInt32(ctx) + return encodeCompileInt32(ctx) case reflect.Int64: - return e.compileInt64(ctx) + return encodeCompileInt64(ctx) case reflect.Uint: - return e.compileUint(ctx) + return encodeCompileUint(ctx) case reflect.Uint8: - return e.compileUint8(ctx) + return encodeCompileUint8(ctx) case reflect.Uint16: - return e.compileUint16(ctx) + return encodeCompileUint16(ctx) case reflect.Uint32: - return e.compileUint32(ctx) + return encodeCompileUint32(ctx) case reflect.Uint64: - return e.compileUint64(ctx) + return encodeCompileUint64(ctx) case reflect.Uintptr: - return e.compileUint(ctx) + return encodeCompileUint(ctx) case reflect.Float32: - return e.compileFloat32(ctx) + return encodeCompileFloat32(ctx) case reflect.Float64: - return e.compileFloat64(ctx) + return encodeCompileFloat64(ctx) case reflect.String: - return e.compileString(ctx) + return encodeCompileString(ctx) case reflect.Bool: - return e.compileBool(ctx) + return encodeCompileBool(ctx) } return nil, &UnsupportedTypeError{Type: rtype2type(typ)} } -func (e *Encoder) compileKey(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileKey(ctx *encodeCompileContext) (*opcode, error) { typ := ctx.typ switch { case rtype_ptrTo(typ).Implements(marshalJSONType): - return e.compileMarshalJSONPtr(ctx) + return encodeCompileMarshalJSONPtr(ctx) case rtype_ptrTo(typ).Implements(marshalTextType): - return e.compileMarshalTextPtr(ctx) + return encodeCompileMarshalTextPtr(ctx) } switch typ.Kind() { case reflect.Ptr: - return e.compilePtr(ctx) + return encodeCompilePtr(ctx) case reflect.Interface: - return e.compileInterface(ctx) + return encodeCompileInterface(ctx) case reflect.String: - return e.compileString(ctx) + return encodeCompileString(ctx) case reflect.Int: - return e.compileIntString(ctx) + return encodeCompileIntString(ctx) case reflect.Int8: - return e.compileInt8String(ctx) + return encodeCompileInt8String(ctx) case reflect.Int16: - return e.compileInt16String(ctx) + return encodeCompileInt16String(ctx) case reflect.Int32: - return e.compileInt32String(ctx) + return encodeCompileInt32String(ctx) case reflect.Int64: - return e.compileInt64String(ctx) + return encodeCompileInt64String(ctx) case reflect.Uint: - return e.compileUintString(ctx) + return encodeCompileUintString(ctx) case reflect.Uint8: - return e.compileUint8String(ctx) + return encodeCompileUint8String(ctx) case reflect.Uint16: - return e.compileUint16String(ctx) + return encodeCompileUint16String(ctx) case reflect.Uint32: - return e.compileUint32String(ctx) + return encodeCompileUint32String(ctx) case reflect.Uint64: - return e.compileUint64String(ctx) + return encodeCompileUint64String(ctx) case reflect.Uintptr: - return e.compileUintString(ctx) + return encodeCompileUintString(ctx) } return nil, &UnsupportedTypeError{Type: rtype2type(typ)} } -func (e *Encoder) compilePtr(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompilePtr(ctx *encodeCompileContext) (*opcode, error) { ptrOpcodeIndex := ctx.opcodeIndex ptrIndex := ctx.ptrIndex ctx.incIndex() - code, err := e.compile(ctx.withType(ctx.typ.Elem())) + code, err := encodeCompile(ctx.withType(ctx.typ.Elem())) if err != nil { return nil, err } @@ -324,187 +479,187 @@ func (e *Encoder) compilePtr(ctx *encodeCompileContext) (*opcode, error) { return newOpCodeWithNext(c, opPtr, code), nil } -func (e *Encoder) compileMarshalJSON(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileMarshalJSON(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opMarshalJSON) ctx.incIndex() return code, nil } -func (e *Encoder) compileMarshalJSONPtr(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileMarshalJSONPtr(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx.withType(rtype_ptrTo(ctx.typ)), opMarshalJSON) ctx.incIndex() return code, nil } -func (e *Encoder) compileMarshalText(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileMarshalText(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opMarshalText) ctx.incIndex() return code, nil } -func (e *Encoder) compileMarshalTextPtr(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileMarshalTextPtr(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx.withType(rtype_ptrTo(ctx.typ)), opMarshalText) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt8(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt8(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt8) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt16(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt16(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt16) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt32(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt32(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt32) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt64(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt64(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt64) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint8(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint8(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint8) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint16(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint16(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint16) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint32(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint32(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint32) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint64(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint64(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint64) ctx.incIndex() return code, nil } -func (e *Encoder) compileIntString(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileIntString(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opIntString) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt8String(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt8String(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt8String) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt16String(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt16String(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt16String) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt32String(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt32String(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt32String) ctx.incIndex() return code, nil } -func (e *Encoder) compileInt64String(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInt64String(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opInt64String) ctx.incIndex() return code, nil } -func (e *Encoder) compileUintString(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUintString(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUintString) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint8String(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint8String(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint8String) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint16String(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint16String(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint16String) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint32String(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint32String(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint32String) ctx.incIndex() return code, nil } -func (e *Encoder) compileUint64String(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileUint64String(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opUint64String) ctx.incIndex() return code, nil } -func (e *Encoder) compileFloat32(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileFloat32(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opFloat32) ctx.incIndex() return code, nil } -func (e *Encoder) compileFloat64(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileFloat64(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opFloat64) ctx.incIndex() return code, nil } -func (e *Encoder) compileString(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileString(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opString) ctx.incIndex() return code, nil } -func (e *Encoder) compileBool(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileBool(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opBool) ctx.incIndex() return code, nil } -func (e *Encoder) compileBytes(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileBytes(ctx *encodeCompileContext) (*opcode, error) { code := newOpCode(ctx, opBytes) ctx.incIndex() return code, nil } -func (e *Encoder) compileInterface(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileInterface(ctx *encodeCompileContext) (*opcode, error) { code := newInterfaceCode(ctx) ctx.incIndex() return code, nil } -func (e *Encoder) compileSlice(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileSlice(ctx *encodeCompileContext) (*opcode, error) { ctx.root = false elem := ctx.typ.Elem() size := elem.Size() @@ -512,7 +667,7 @@ func (e *Encoder) compileSlice(ctx *encodeCompileContext) (*opcode, error) { header := newSliceHeaderCode(ctx) ctx.incIndex() - code, err := e.compile(ctx.withType(ctx.typ.Elem()).incIndent()) + code, err := encodeCompile(ctx.withType(ctx.typ.Elem()).incIndent()) if err != nil { return nil, err } @@ -536,7 +691,7 @@ func (e *Encoder) compileSlice(ctx *encodeCompileContext) (*opcode, error) { return (*opcode)(unsafe.Pointer(header)), nil } -func (e *Encoder) compileArray(ctx *encodeCompileContext) (*opcode, error) { +func encodeCompileArray(ctx *encodeCompileContext) (*opcode, error) { ctx.root = false typ := ctx.typ elem := typ.Elem() @@ -546,7 +701,7 @@ func (e *Encoder) compileArray(ctx *encodeCompileContext) (*opcode, error) { header := newArrayHeaderCode(ctx, alen) ctx.incIndex() - code, err := e.compile(ctx.withType(elem).incIndent()) + code, err := encodeCompile(ctx.withType(elem).incIndent()) if err != nil { return nil, err } @@ -585,7 +740,7 @@ func mapiternext(it unsafe.Pointer) //go:noescape func maplen(m unsafe.Pointer) int -func (e *Encoder) compileMap(ctx *encodeCompileContext, withLoad bool) (*opcode, error) { +func encodeCompileMap(ctx *encodeCompileContext, withLoad bool) (*opcode, error) { // header => code => value => code => key => code => value => code => end // ^ | // |_______________________| @@ -595,7 +750,7 @@ func (e *Encoder) compileMap(ctx *encodeCompileContext, withLoad bool) (*opcode, typ := ctx.typ keyType := ctx.typ.Key() - keyCode, err := e.compileKey(ctx.withType(keyType)) + keyCode, err := encodeCompileKey(ctx.withType(keyType)) if err != nil { return nil, err } @@ -604,7 +759,7 @@ func (e *Encoder) compileMap(ctx *encodeCompileContext, withLoad bool) (*opcode, ctx.incIndex() valueType := typ.Elem() - valueCode, err := e.compile(ctx.withType(valueType)) + valueCode, err := encodeCompile(ctx.withType(valueType)) if err != nil { return nil, err } @@ -633,7 +788,7 @@ func (e *Encoder) compileMap(ctx *encodeCompileContext, withLoad bool) (*opcode, return (*opcode)(unsafe.Pointer(header)), nil } -func (e *Encoder) typeToHeaderType(ctx *encodeCompileContext, code *opcode) opType { +func encodeTypeToHeaderType(ctx *encodeCompileContext, code *opcode) opType { switch code.op { case opPtr: ptrNum := 1 @@ -757,7 +912,7 @@ func (e *Encoder) typeToHeaderType(ctx *encodeCompileContext, code *opcode) opTy return opStructFieldHead } -func (e *Encoder) typeToFieldType(ctx *encodeCompileContext, code *opcode) opType { +func encodeTypeToFieldType(ctx *encodeCompileContext, code *opcode) opType { switch code.op { case opPtr: ptrNum := 1 @@ -881,8 +1036,8 @@ func (e *Encoder) typeToFieldType(ctx *encodeCompileContext, code *opcode) opTyp return opStructField } -func (e *Encoder) optimizeStructHeader(ctx *encodeCompileContext, code *opcode, tag *structTag) opType { - headType := e.typeToHeaderType(ctx, code) +func encodeOptimizeStructHeader(ctx *encodeCompileContext, code *opcode, tag *structTag) opType { + headType := encodeTypeToHeaderType(ctx, code) switch { case tag.isOmitEmpty: headType = headType.headToOmitEmptyHead() @@ -892,8 +1047,8 @@ func (e *Encoder) optimizeStructHeader(ctx *encodeCompileContext, code *opcode, return headType } -func (e *Encoder) optimizeStructField(ctx *encodeCompileContext, code *opcode, tag *structTag) opType { - fieldType := e.typeToFieldType(ctx, code) +func encodeOptimizeStructField(ctx *encodeCompileContext, code *opcode, tag *structTag) opType { + fieldType := encodeTypeToFieldType(ctx, code) switch { case tag.isOmitEmpty: fieldType = fieldType.fieldToOmitEmptyField() @@ -903,24 +1058,24 @@ func (e *Encoder) optimizeStructField(ctx *encodeCompileContext, code *opcode, t return fieldType } -func (e *Encoder) recursiveCode(ctx *encodeCompileContext, jmp *compiledCode) *opcode { +func encodeRecursiveCode(ctx *encodeCompileContext, jmp *compiledCode) *opcode { code := newRecursiveCode(ctx, jmp) ctx.incIndex() return code } -func (e *Encoder) compiledCode(ctx *encodeCompileContext) *opcode { +func encodeCompiledCode(ctx *encodeCompileContext) *opcode { typ := ctx.typ typeptr := uintptr(unsafe.Pointer(typ)) if compiledCode, exists := ctx.structTypeToCompiledCode[typeptr]; exists { - return e.recursiveCode(ctx, compiledCode) + return encodeRecursiveCode(ctx, compiledCode) } return nil } -func (e *Encoder) structHeader(ctx *encodeCompileContext, fieldCode *opcode, valueCode *opcode, tag *structTag) *opcode { +func encodeStructHeader(ctx *encodeCompileContext, fieldCode *opcode, valueCode *opcode, tag *structTag) *opcode { fieldCode.indent-- - op := e.optimizeStructHeader(ctx, valueCode, tag) + op := encodeOptimizeStructHeader(ctx, valueCode, tag) fieldCode.op = op fieldCode.ptrNum = valueCode.ptrNum switch op { @@ -943,9 +1098,9 @@ func (e *Encoder) structHeader(ctx *encodeCompileContext, fieldCode *opcode, val return (*opcode)(unsafe.Pointer(fieldCode)) } -func (e *Encoder) structField(ctx *encodeCompileContext, fieldCode *opcode, valueCode *opcode, tag *structTag) *opcode { +func encodeStructField(ctx *encodeCompileContext, fieldCode *opcode, valueCode *opcode, tag *structTag) *opcode { code := (*opcode)(unsafe.Pointer(fieldCode)) - op := e.optimizeStructField(ctx, valueCode, tag) + op := encodeOptimizeStructField(ctx, valueCode, tag) fieldCode.op = op fieldCode.ptrNum = valueCode.ptrNum switch op { @@ -968,7 +1123,7 @@ func (e *Encoder) structField(ctx *encodeCompileContext, fieldCode *opcode, valu return code } -func (e *Encoder) isNotExistsField(head *opcode) bool { +func encodeIsNotExistsField(head *opcode) bool { if head == nil { return false } @@ -990,10 +1145,10 @@ func (e *Encoder) isNotExistsField(head *opcode) bool { if head.next.op.codeType() != codeStructField { return false } - return e.isNotExistsField(head.next) + return encodeIsNotExistsField(head.next) } -func (e *Encoder) optimizeAnonymousFields(head *opcode) { +func encodeOptimizeAnonymousFields(head *opcode) { code := head var prev *opcode removedFields := map[*opcode]struct{}{} @@ -1004,13 +1159,13 @@ func (e *Encoder) optimizeAnonymousFields(head *opcode) { if code.op == opStructField { codeType := code.next.op.codeType() if codeType == codeStructField { - if e.isNotExistsField(code.next) { + if encodeIsNotExistsField(code.next) { code.next = code.nextField diff := code.next.displayIdx - code.displayIdx for i := 0; i < diff; i++ { code.next.decOpcodeIndex() } - linkPrevToNextField(code, removedFields) + encodeLinkPrevToNextField(code, removedFields) code = prev } } @@ -1027,7 +1182,7 @@ type structFieldPair struct { linked bool } -func (e *Encoder) anonymousStructFieldPairMap(typ *rtype, tags structTags, named string, valueCode *opcode) map[string][]structFieldPair { +func encodeAnonymousStructFieldPairMap(typ *rtype, tags structTags, named string, valueCode *opcode) map[string][]structFieldPair { anonymousFields := map[string][]structFieldPair{} f := valueCode var prevAnonymousField *opcode @@ -1050,7 +1205,7 @@ func (e *Encoder) anonymousStructFieldPairMap(typ *rtype, tags structTags, named for i := 0; i < diff; i++ { f.nextField.decOpcodeIndex() } - linkPrevToNextField(f, removedFields) + encodeLinkPrevToNextField(f, removedFields) } if f.displayKey == "" { @@ -1069,7 +1224,7 @@ func (e *Encoder) anonymousStructFieldPairMap(typ *rtype, tags structTags, named isTaggedKey: f.isTaggedKey, }) if f.next != nil && f.nextField != f.next && f.next.op.codeType() == codeStructField { - for k, v := range e.anonymousStructFieldPairMap(typ, tags, named, f.next) { + for k, v := range encodeAnonymousStructFieldPairMap(typ, tags, named, f.next) { anonymousFields[k] = append(anonymousFields[k], v...) } } @@ -1082,7 +1237,7 @@ func (e *Encoder) anonymousStructFieldPairMap(typ *rtype, tags structTags, named return anonymousFields } -func (e *Encoder) optimizeConflictAnonymousFields(anonymousFields map[string][]structFieldPair) { +func encodeOptimizeConflictAnonymousFields(anonymousFields map[string][]structFieldPair) { removedFields := map[*opcode]struct{}{} for _, fieldPairs := range anonymousFields { if len(fieldPairs) == 1 { @@ -1104,7 +1259,7 @@ func (e *Encoder) optimizeConflictAnonymousFields(anonymousFields map[string][]s fieldPair.curField.nextField.decOpcodeIndex() } removedFields[fieldPair.curField] = struct{}{} - linkPrevToNextField(fieldPair.curField, removedFields) + encodeLinkPrevToNextField(fieldPair.curField, removedFields) } fieldPair.linked = true } @@ -1122,7 +1277,7 @@ func (e *Encoder) optimizeConflictAnonymousFields(anonymousFields map[string][]s for i := 0; i < diff; i++ { fieldPair.curField.nextField.decOpcodeIndex() } - linkPrevToNextField(fieldPair.curField, removedFields) + encodeLinkPrevToNextField(fieldPair.curField, removedFields) } fieldPair.linked = true } @@ -1135,9 +1290,9 @@ func (e *Encoder) optimizeConflictAnonymousFields(anonymousFields map[string][]s } } -func (e *Encoder) compileStruct(ctx *encodeCompileContext, isPtr bool) (*opcode, error) { +func encodeCompileStruct(ctx *encodeCompileContext, isPtr bool) (*opcode, error) { ctx.root = false - if code := e.compiledCode(ctx); code != nil { + if code := encodeCompiledCode(ctx); code != nil { return code, nil } typ := ctx.typ @@ -1179,7 +1334,7 @@ func (e *Encoder) compileStruct(ctx *encodeCompileContext, isPtr bool) (*opcode, fieldOpcodeIndex := ctx.opcodeIndex fieldPtrIndex := ctx.ptrIndex ctx.incIndex() - valueCode, err := e.compile(ctx.withType(fieldType)) + valueCode, err := encodeCompile(ctx.withType(fieldType)) if err != nil { return nil, err } @@ -1195,7 +1350,7 @@ func (e *Encoder) compileStruct(ctx *encodeCompileContext, isPtr bool) (*opcode, if tag.isTaggedKey { tagKey = tag.key } - for k, v := range e.anonymousStructFieldPairMap(typ, tags, tagKey, valueCode) { + for k, v := range encodeAnonymousStructFieldPairMap(typ, tags, tagKey, valueCode) { anonymousFields[k] = append(anonymousFields[k], v...) } } @@ -1216,13 +1371,13 @@ func (e *Encoder) compileStruct(ctx *encodeCompileContext, isPtr bool) (*opcode, } if fieldIdx == 0 { fieldCode.headIdx = fieldCode.idx - code = e.structHeader(ctx, fieldCode, valueCode, tag) + code = encodeStructHeader(ctx, fieldCode, valueCode, tag) head = fieldCode prevField = fieldCode } else { fieldCode.headIdx = head.headIdx code.next = fieldCode - code = e.structField(ctx, fieldCode, valueCode, tag) + code = encodeStructField(ctx, fieldCode, valueCode, tag) prevField.nextField = fieldCode fieldCode.prevField = prevField prevField = fieldCode @@ -1265,8 +1420,8 @@ func (e *Encoder) compileStruct(ctx *encodeCompileContext, isPtr bool) (*opcode, head.end = structEndCode code.next = structEndCode - e.optimizeConflictAnonymousFields(anonymousFields) - e.optimizeAnonymousFields(head) + encodeOptimizeConflictAnonymousFields(anonymousFields) + encodeOptimizeAnonymousFields(head) ret := (*opcode)(unsafe.Pointer(head)) compiled.code = ret diff --git a/encode_context.go b/encode_context.go index dca785f..692f9d7 100644 --- a/encode_context.go +++ b/encode_context.go @@ -142,9 +142,13 @@ func (c *encodeCompileContext) decPtrIndex() { } type encodeRuntimeContext struct { - ptrs []uintptr - keepRefs []unsafe.Pointer - seenPtr []uintptr + buf []byte + ptrs []uintptr + keepRefs []unsafe.Pointer + seenPtr []uintptr + baseIndent int + prefix []byte + indentStr []byte } func (c *encodeRuntimeContext) init(p uintptr, codelen int) { @@ -154,6 +158,7 @@ func (c *encodeRuntimeContext) init(p uintptr, codelen int) { c.ptrs[0] = p c.keepRefs = c.keepRefs[:0] c.seenPtr = c.seenPtr[:0] + c.baseIndent = 0 } func (c *encodeRuntimeContext) ptr() uintptr { diff --git a/encode_opcode.go b/encode_opcode.go index cf3d013..96492e2 100644 --- a/encode_opcode.go +++ b/encode_opcode.go @@ -327,7 +327,7 @@ func nextField(code *opcode, removedFields map[*opcode]struct{}) *opcode { return code } -func linkPrevToNextField(cur *opcode, removedFields map[*opcode]struct{}) { +func encodeLinkPrevToNextField(cur *opcode, removedFields map[*opcode]struct{}) { prev := prevField(cur.prevField, removedFields) prev.nextField = nextField(cur.nextField, removedFields) code := prev diff --git a/encode_vm.go b/encode_vm.go index 8f78dd8..8690f07 100644 --- a/encode_vm.go +++ b/encode_vm.go @@ -24,6 +24,36 @@ func store(base uintptr, idx uintptr, p uintptr) { **(**uintptr)(unsafe.Pointer(&addr)) = p } +func ptrToInt(p uintptr) int { return **(**int)(unsafe.Pointer(&p)) } +func ptrToInt8(p uintptr) int8 { return **(**int8)(unsafe.Pointer(&p)) } +func ptrToInt16(p uintptr) int16 { return **(**int16)(unsafe.Pointer(&p)) } +func ptrToInt32(p uintptr) int32 { return **(**int32)(unsafe.Pointer(&p)) } +func ptrToInt64(p uintptr) int64 { return **(**int64)(unsafe.Pointer(&p)) } +func ptrToUint(p uintptr) uint { return **(**uint)(unsafe.Pointer(&p)) } +func ptrToUint8(p uintptr) uint8 { return **(**uint8)(unsafe.Pointer(&p)) } +func ptrToUint16(p uintptr) uint16 { return **(**uint16)(unsafe.Pointer(&p)) } +func ptrToUint32(p uintptr) uint32 { return **(**uint32)(unsafe.Pointer(&p)) } +func ptrToUint64(p uintptr) uint64 { return **(**uint64)(unsafe.Pointer(&p)) } +func ptrToFloat32(p uintptr) float32 { return **(**float32)(unsafe.Pointer(&p)) } +func ptrToFloat64(p uintptr) float64 { return **(**float64)(unsafe.Pointer(&p)) } +func ptrToBool(p uintptr) bool { return **(**bool)(unsafe.Pointer(&p)) } +func ptrToByte(p uintptr) byte { return **(**byte)(unsafe.Pointer(&p)) } +func ptrToBytes(p uintptr) []byte { return **(**[]byte)(unsafe.Pointer(&p)) } +func ptrToString(p uintptr) string { return **(**string)(unsafe.Pointer(&p)) } +func ptrToSlice(p uintptr) *sliceHeader { return *(**sliceHeader)(unsafe.Pointer(&p)) } +func ptrToPtr(p uintptr) uintptr { + return uintptr(**(**unsafe.Pointer)(unsafe.Pointer(&p))) +} +func ptrToUnsafePtr(p uintptr) unsafe.Pointer { + return *(*unsafe.Pointer)(unsafe.Pointer(&p)) +} +func ptrToInterface(code *opcode, p uintptr) interface{} { + return *(*interface{})(unsafe.Pointer(&interfaceHeader{ + typ: code.typ, + ptr: *(*unsafe.Pointer)(unsafe.Pointer(&p)), + })) +} + func errUnsupportedValue(code *opcode, ptr uintptr) *UnsupportedValueError { v := *(*interface{})(unsafe.Pointer(&interfaceHeader{ typ: code.typ, @@ -49,7 +79,7 @@ func errMarshaler(code *opcode, err error) *MarshalerError { } } -func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ([]byte, error) { +func encodeRun(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, opt EncodeOption) ([]byte, error) { recursiveLevel := 0 ptrOffset := uintptr(0) ctxptr := ctx.ptr() @@ -62,113 +92,113 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opPtr: ptr := load(ctxptr, code.idx) code = code.next - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) case opInt: - b = appendInt(b, int64(e.ptrToInt(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opInt8: - b = appendInt(b, int64(e.ptrToInt8(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt8(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opInt16: - b = appendInt(b, int64(e.ptrToInt16(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt16(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opInt32: - b = appendInt(b, int64(e.ptrToInt32(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt32(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opInt64: - b = appendInt(b, e.ptrToInt64(load(ctxptr, code.idx))) + b = appendInt(b, ptrToInt64(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opUint: - b = appendUint(b, uint64(e.ptrToUint(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opUint8: - b = appendUint(b, uint64(e.ptrToUint8(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint8(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opUint16: - b = appendUint(b, uint64(e.ptrToUint16(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint16(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opUint32: - b = appendUint(b, uint64(e.ptrToUint32(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint32(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opUint64: - b = appendUint(b, e.ptrToUint64(load(ctxptr, code.idx))) + b = appendUint(b, ptrToUint64(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opIntString: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opInt8String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt8(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opInt16String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt16(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opInt32String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt32(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opInt64String: b = append(b, '"') - b = appendInt(b, e.ptrToInt64(load(ctxptr, code.idx))) + b = appendInt(b, ptrToInt64(load(ctxptr, code.idx))) b = append(b, '"') b = encodeComma(b) code = code.next case opUintString: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opUint8String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint8(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opUint16String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint16(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opUint32String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint32(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opUint64String: b = append(b, '"') - b = appendUint(b, e.ptrToUint64(load(ctxptr, code.idx))) + b = appendUint(b, ptrToUint64(load(ctxptr, code.idx))) b = append(b, '"') b = encodeComma(b) code = code.next case opFloat32: - b = encodeFloat32(b, e.ptrToFloat32(load(ctxptr, code.idx))) + b = encodeFloat32(b, ptrToFloat32(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opFloat64: - v := e.ptrToFloat64(load(ctxptr, code.idx)) + v := ptrToFloat64(load(ctxptr, code.idx)) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -176,20 +206,20 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeComma(b) code = code.next case opString: - b = encodeNoEscapedString(b, e.ptrToString(load(ctxptr, code.idx))) + b = encodeNoEscapedString(b, ptrToString(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opBool: - b = encodeBool(b, e.ptrToBool(load(ctxptr, code.idx))) + b = encodeBool(b, ptrToBool(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opBytes: ptr := load(ctxptr, code.idx) - slice := e.ptrToSlice(ptr) + slice := ptrToSlice(ptr) if ptr == 0 || uintptr(slice.data) == 0 { b = encodeNull(b) } else { - b = encodeByteSlice(b, e.ptrToBytes(ptr)) + b = encodeByteSlice(b, ptrToBytes(ptr)) } b = encodeComma(b) code = code.next @@ -207,7 +237,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } } ctx.seenPtr = append(ctx.seenPtr, ptr) - iface := (*interfaceHeader)(e.ptrToUnsafePtr(ptr)) + iface := (*interfaceHeader)(ptrToUnsafePtr(ptr)) if iface == nil || iface.ptr == nil { b = encodeNull(b) b = encodeComma(b) @@ -215,7 +245,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(iface)) - ifaceCodeSet, err := e.compileToGetCodeSet(uintptr(unsafe.Pointer(iface.typ))) + ifaceCodeSet, err := encodeCompileToGetCodeSet(uintptr(unsafe.Pointer(iface.typ))) if err != nil { return nil, err } @@ -237,7 +267,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ctx.ptrs = newPtrs - bb, err := e.run(ctx, b, ifaceCodeSet) + bb, err := encodeRun(ctx, b, ifaceCodeSet, opt) if err != nil { return nil, err } @@ -256,7 +286,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next break } - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -279,7 +309,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opMarshalText: ptr := load(ctxptr, code.idx) isPtr := code.typ.Kind() == reflect.Ptr - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) if p == nil || isPtr && *(*unsafe.Pointer)(p) == nil { b = append(b, '"', '"', ',') } else { @@ -297,7 +327,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next case opSliceHead: p := load(ctxptr, code.idx) - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) if p == 0 || uintptr(slice.data) == 0 { b = encodeNull(b) b = encodeComma(b) @@ -370,7 +400,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeComma(b) code = code.end.next } else { - uptr := e.ptrToUnsafePtr(ptr) + uptr := ptrToUnsafePtr(ptr) mlen := maplen(uptr) if mlen > 0 { b = append(b, '{') @@ -379,7 +409,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( store(ctxptr, code.elemIdx, 0) store(ctxptr, code.length, uintptr(mlen)) store(ctxptr, code.mapIter, uintptr(iter)) - if !e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) == 0 { mapCtx := newMapContext(mlen) mapCtx.pos = append(mapCtx.pos, len(b)) ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) @@ -401,8 +431,8 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { // load pointer - ptr = e.ptrToPtr(ptr) - uptr := e.ptrToUnsafePtr(ptr) + ptr = ptrToPtr(ptr) + uptr := ptrToUnsafePtr(ptr) if ptr == 0 { b = encodeNull(b) b = encodeComma(b) @@ -419,7 +449,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( store(ctxptr, code.mapIter, uintptr(iter)) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) - if !e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) == 0 { mapCtx := newMapContext(mlen) mapCtx.pos = append(mapCtx.pos, len(b)) ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) @@ -435,10 +465,10 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( idx := load(ctxptr, code.elemIdx) length := load(ctxptr, code.length) idx++ - if e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) != 0 { if idx < length { ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) store(ctxptr, code.elemIdx, idx) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) @@ -451,11 +481,11 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } } else { ptr := load(ctxptr, code.end.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) mapCtx.pos = append(mapCtx.pos, len(b)) if idx < length { ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) store(ctxptr, code.elemIdx, idx) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) @@ -465,16 +495,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } } case opMapValue: - if e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) != 0 { last := len(b) - 1 b[last] = ':' } else { ptr := load(ctxptr, code.end.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) mapCtx.pos = append(mapCtx.pos, len(b)) } ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) value := mapitervalue(iter) store(ctxptr, code.next.idx, uintptr(value)) mapiternext(iter) @@ -483,7 +513,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( // this operation only used by sorted map. length := int(load(ctxptr, code.length)) ptr := load(ctxptr, code.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) pos := mapCtx.pos for i := 0; i < length; i++ { startKey := pos[i*2] @@ -514,7 +544,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( releaseMapContext(mapCtx) code = code.next case opStructFieldPtrAnonymousHeadRecursive: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadRecursive: fallthrough @@ -555,7 +585,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ctx.seenPtr = ctx.seenPtr[:len(ctx.seenPtr)-1] codePtr := load(ctxptr, code.elemIdx) - code = (*opcode)(e.ptrToUnsafePtr(codePtr)) + code = (*opcode)(ptrToUnsafePtr(codePtr)) ctxptr = ctx.ptr() + offset ptrOffset = offset case opStructFieldPtrHead: @@ -565,7 +595,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHead: ptr := load(ctxptr, code.idx) @@ -585,7 +615,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmpty: @@ -638,7 +668,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmpty: @@ -656,7 +686,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } } case opStructFieldPtrHeadInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt: ptr := load(ctxptr, code.idx) @@ -667,14 +697,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt: @@ -685,7 +715,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -698,7 +728,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt: @@ -711,7 +741,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -720,13 +750,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyIntOnly, opStructFieldHeadOmitEmptyIntOnly: p := load(ctxptr, code.idx) b = append(b, '{') - v := int64(e.ptrToInt(p)) + v := int64(ptrToInt(p)) if v != 0 { b = append(b, code.key...) b = appendInt(b, v) @@ -738,12 +768,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadIntPtr: p := load(ctxptr, code.idx) @@ -755,17 +785,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyIntPtr: p := load(ctxptr, code.idx) @@ -775,16 +805,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagIntPtr: p := load(ctxptr, code.idx) @@ -796,12 +826,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } } @@ -815,7 +845,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadIntPtrOnly: p := load(ctxptr, code.idx) @@ -824,7 +854,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeComma(b) code = code.next @@ -836,14 +866,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyIntPtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = encodeComma(b) } code = code.next @@ -855,7 +885,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) @@ -865,7 +895,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -881,18 +911,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt: ptr := load(ctxptr, code.idx) @@ -900,14 +930,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt: @@ -915,7 +945,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -928,7 +958,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt: @@ -938,7 +968,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -949,7 +979,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -958,7 +988,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -975,13 +1005,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadIntPtr: p := load(ctxptr, code.idx) @@ -990,16 +1020,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyIntPtr: p := load(ctxptr, code.idx) @@ -1007,17 +1037,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagIntPtr: p := load(ctxptr, code.idx) @@ -1026,12 +1056,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1042,7 +1072,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadIntPtrOnly: p := load(ctxptr, code.idx) @@ -1050,7 +1080,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1060,7 +1090,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyIntPtrOnly: p := load(ctxptr, code.idx) @@ -1068,7 +1098,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = encodeComma(b) code = code.next } @@ -1078,7 +1108,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) @@ -1087,13 +1117,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt8: ptr := load(ctxptr, code.idx) @@ -1104,14 +1134,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt8: @@ -1122,7 +1152,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1135,7 +1165,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt8: @@ -1148,7 +1178,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1157,13 +1187,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt8Only, opStructFieldHeadOmitEmptyInt8Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := int64(e.ptrToInt8(p)) + v := int64(ptrToInt8(p)) if v != 0 { b = append(b, code.key...) b = appendInt(b, v) @@ -1175,12 +1205,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt8Ptr: p := load(ctxptr, code.idx) @@ -1192,17 +1222,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt8Ptr: p := load(ctxptr, code.idx) @@ -1212,16 +1242,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt8Ptr: p := load(ctxptr, code.idx) @@ -1233,12 +1263,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } } @@ -1252,7 +1282,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1261,7 +1291,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1273,14 +1303,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt8PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = encodeComma(b) } code = code.next @@ -1292,7 +1322,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1302,7 +1332,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1318,18 +1348,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt8: ptr := load(ctxptr, code.idx) @@ -1337,14 +1367,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8: @@ -1352,7 +1382,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1365,7 +1395,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt8: @@ -1375,7 +1405,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1386,7 +1416,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -1395,7 +1425,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1412,13 +1442,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt8Ptr: p := load(ctxptr, code.idx) @@ -1427,16 +1457,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8Ptr: p := load(ctxptr, code.idx) @@ -1444,17 +1474,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt8Ptr: p := load(ctxptr, code.idx) @@ -1463,12 +1493,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1479,7 +1509,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1487,7 +1517,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1497,7 +1527,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1505,7 +1535,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = encodeComma(b) code = code.next } @@ -1515,7 +1545,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1524,13 +1554,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt16: ptr := load(ctxptr, code.idx) @@ -1541,14 +1571,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt16: @@ -1559,7 +1589,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1572,7 +1602,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt16: @@ -1585,7 +1615,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1594,13 +1624,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt16Only, opStructFieldHeadOmitEmptyInt16Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := int64(e.ptrToInt16(p)) + v := int64(ptrToInt16(p)) if v != 0 { b = append(b, code.key...) b = appendInt(b, v) @@ -1612,12 +1642,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt16Ptr: p := load(ctxptr, code.idx) @@ -1629,17 +1659,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt16Ptr: p := load(ctxptr, code.idx) @@ -1649,16 +1679,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt16Ptr: p := load(ctxptr, code.idx) @@ -1670,12 +1700,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } } @@ -1689,7 +1719,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1698,7 +1728,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1710,14 +1740,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt16PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = encodeComma(b) } code = code.next @@ -1729,7 +1759,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1739,7 +1769,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1755,18 +1785,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt16: ptr := load(ctxptr, code.idx) @@ -1774,14 +1804,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16: @@ -1789,7 +1819,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1802,7 +1832,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt16: @@ -1812,7 +1842,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1823,7 +1853,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -1832,7 +1862,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1849,13 +1879,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt16Ptr: p := load(ctxptr, code.idx) @@ -1864,16 +1894,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16Ptr: p := load(ctxptr, code.idx) @@ -1881,17 +1911,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt16Ptr: p := load(ctxptr, code.idx) @@ -1900,12 +1930,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1916,7 +1946,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1924,7 +1954,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1934,7 +1964,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1942,7 +1972,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = encodeComma(b) code = code.next } @@ -1952,7 +1982,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1961,13 +1991,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt32: ptr := load(ctxptr, code.idx) @@ -1978,14 +2008,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt32: @@ -1996,7 +2026,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2009,7 +2039,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt32: @@ -2022,7 +2052,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2031,13 +2061,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt32Only, opStructFieldHeadOmitEmptyInt32Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := int64(e.ptrToInt32(p)) + v := int64(ptrToInt32(p)) if v != 0 { b = append(b, code.key...) b = appendInt(b, v) @@ -2049,12 +2079,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt32Ptr: p := load(ctxptr, code.idx) @@ -2066,17 +2096,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt32Ptr: p := load(ctxptr, code.idx) @@ -2086,16 +2116,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt32Ptr: p := load(ctxptr, code.idx) @@ -2107,12 +2137,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } } @@ -2126,7 +2156,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2135,7 +2165,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeComma(b) code = code.next @@ -2147,14 +2177,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt32PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = encodeComma(b) } code = code.next @@ -2166,7 +2196,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2176,7 +2206,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -2192,18 +2222,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt32: ptr := load(ctxptr, code.idx) @@ -2211,14 +2241,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32: @@ -2226,7 +2256,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2239,7 +2269,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt32: @@ -2249,7 +2279,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2260,7 +2290,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -2269,7 +2299,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2286,13 +2316,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt32Ptr: p := load(ctxptr, code.idx) @@ -2301,16 +2331,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32Ptr: p := load(ctxptr, code.idx) @@ -2318,17 +2348,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt32Ptr: p := load(ctxptr, code.idx) @@ -2337,12 +2367,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -2353,7 +2383,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2361,7 +2391,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeComma(b) code = code.next @@ -2371,7 +2401,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2379,7 +2409,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = encodeComma(b) code = code.next } @@ -2389,7 +2419,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2398,13 +2428,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt64: ptr := load(ctxptr, code.idx) @@ -2415,14 +2445,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt64: @@ -2433,7 +2463,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2446,7 +2476,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt64: @@ -2459,7 +2489,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2468,13 +2498,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt64Only, opStructFieldHeadOmitEmptyInt64Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToInt64(p) + v := ptrToInt64(p) if v != 0 { b = append(b, code.key...) b = appendInt(b, v) @@ -2486,12 +2516,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt64Ptr: p := load(ctxptr, code.idx) @@ -2503,17 +2533,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt64Ptr: p := load(ctxptr, code.idx) @@ -2523,16 +2553,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt64Ptr: p := load(ctxptr, code.idx) @@ -2544,12 +2574,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } } @@ -2563,7 +2593,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2572,7 +2602,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeComma(b) code = code.next @@ -2584,14 +2614,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt64PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = encodeComma(b) } code = code.next @@ -2603,7 +2633,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2613,7 +2643,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -2629,18 +2659,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt64: ptr := load(ctxptr, code.idx) @@ -2648,14 +2678,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64: @@ -2663,7 +2693,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2676,7 +2706,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt64: @@ -2686,7 +2716,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2697,7 +2727,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -2706,7 +2736,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2723,13 +2753,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt64Ptr: p := load(ctxptr, code.idx) @@ -2738,16 +2768,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64Ptr: p := load(ctxptr, code.idx) @@ -2755,17 +2785,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt64Ptr: p := load(ctxptr, code.idx) @@ -2774,12 +2804,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -2790,7 +2820,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2798,7 +2828,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeComma(b) code = code.next @@ -2808,7 +2838,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2816,7 +2846,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = encodeComma(b) code = code.next } @@ -2826,7 +2856,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2835,13 +2865,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint: ptr := load(ctxptr, code.idx) @@ -2852,14 +2882,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint: @@ -2870,7 +2900,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2883,7 +2913,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint: @@ -2896,7 +2926,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2905,13 +2935,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUintOnly, opStructFieldHeadOmitEmptyUintOnly: p := load(ctxptr, code.idx) b = append(b, '{') - v := uint64(e.ptrToUint(p)) + v := uint64(ptrToUint(p)) if v != 0 { b = append(b, code.key...) b = appendUint(b, v) @@ -2923,12 +2953,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUintPtr: p := load(ctxptr, code.idx) @@ -2940,17 +2970,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUintPtr: p := load(ctxptr, code.idx) @@ -2960,16 +2990,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUintPtr: p := load(ctxptr, code.idx) @@ -2981,12 +3011,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } } @@ -3000,7 +3030,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUintPtrOnly: p := load(ctxptr, code.idx) @@ -3009,7 +3039,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3021,14 +3051,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUintPtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = encodeComma(b) } code = code.next @@ -3040,7 +3070,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) @@ -3050,7 +3080,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3066,18 +3096,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint: ptr := load(ctxptr, code.idx) @@ -3085,14 +3115,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint: @@ -3100,7 +3130,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3113,7 +3143,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint: @@ -3123,7 +3153,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3134,7 +3164,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -3143,7 +3173,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3160,13 +3190,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUintPtr: p := load(ctxptr, code.idx) @@ -3175,16 +3205,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUintPtr: p := load(ctxptr, code.idx) @@ -3192,17 +3222,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUintPtr: p := load(ctxptr, code.idx) @@ -3211,12 +3241,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3227,7 +3257,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUintPtrOnly: p := load(ctxptr, code.idx) @@ -3235,7 +3265,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3245,7 +3275,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUintPtrOnly: p := load(ctxptr, code.idx) @@ -3253,7 +3283,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = encodeComma(b) code = code.next } @@ -3263,7 +3293,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) @@ -3272,13 +3302,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint8: ptr := load(ctxptr, code.idx) @@ -3289,14 +3319,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint8: @@ -3307,7 +3337,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3320,7 +3350,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint8: @@ -3333,7 +3363,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3342,13 +3372,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint8Only, opStructFieldHeadOmitEmptyUint8Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := uint64(e.ptrToUint8(p)) + v := uint64(ptrToUint8(p)) if v != 0 { b = append(b, code.key...) b = appendUint(b, v) @@ -3360,12 +3390,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint8Ptr: p := load(ctxptr, code.idx) @@ -3377,17 +3407,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint8Ptr: p := load(ctxptr, code.idx) @@ -3397,16 +3427,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint8Ptr: p := load(ctxptr, code.idx) @@ -3418,12 +3448,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } } @@ -3437,7 +3467,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3446,7 +3476,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3458,14 +3488,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint8PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = encodeComma(b) } code = code.next @@ -3477,7 +3507,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3487,7 +3517,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3503,18 +3533,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint8: ptr := load(ctxptr, code.idx) @@ -3522,14 +3552,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8: @@ -3537,7 +3567,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3550,7 +3580,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint8: @@ -3560,7 +3590,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3571,7 +3601,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -3580,7 +3610,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3597,13 +3627,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint8Ptr: p := load(ctxptr, code.idx) @@ -3612,16 +3642,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8Ptr: p := load(ctxptr, code.idx) @@ -3629,17 +3659,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint8Ptr: p := load(ctxptr, code.idx) @@ -3648,12 +3678,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3664,7 +3694,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3672,7 +3702,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3682,7 +3712,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3690,7 +3720,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = encodeComma(b) code = code.next } @@ -3700,7 +3730,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3709,13 +3739,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint16: ptr := load(ctxptr, code.idx) @@ -3726,14 +3756,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint16: @@ -3744,7 +3774,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3757,7 +3787,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint16: @@ -3770,7 +3800,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3779,13 +3809,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint16Only, opStructFieldHeadOmitEmptyUint16Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := uint64(e.ptrToUint16(p)) + v := uint64(ptrToUint16(p)) if v != 0 { b = append(b, code.key...) b = appendUint(b, v) @@ -3797,12 +3827,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint16Ptr: p := load(ctxptr, code.idx) @@ -3814,17 +3844,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint16Ptr: p := load(ctxptr, code.idx) @@ -3834,16 +3864,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint16Ptr: p := load(ctxptr, code.idx) @@ -3855,12 +3885,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } } @@ -3874,7 +3904,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint16PtrOnly: p := load(ctxptr, code.idx) @@ -3883,7 +3913,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3895,14 +3925,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint16PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = encodeComma(b) } code = code.next @@ -3914,7 +3944,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) @@ -3924,7 +3954,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3940,18 +3970,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint16: ptr := load(ctxptr, code.idx) @@ -3959,14 +3989,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16: @@ -3974,7 +4004,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3987,7 +4017,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint16: @@ -3997,7 +4027,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4008,7 +4038,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -4017,7 +4047,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4034,13 +4064,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint16Ptr: p := load(ctxptr, code.idx) @@ -4049,16 +4079,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16Ptr: p := load(ctxptr, code.idx) @@ -4066,17 +4096,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint16Ptr: p := load(ctxptr, code.idx) @@ -4085,12 +4115,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -4101,7 +4131,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint16PtrOnly: p := load(ctxptr, code.idx) @@ -4109,7 +4139,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeComma(b) code = code.next @@ -4119,7 +4149,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16PtrOnly: p := load(ctxptr, code.idx) @@ -4127,7 +4157,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = encodeComma(b) code = code.next } @@ -4137,7 +4167,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) @@ -4146,13 +4176,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint32: ptr := load(ctxptr, code.idx) @@ -4163,14 +4193,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint32: @@ -4181,7 +4211,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4194,7 +4224,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint32: @@ -4207,7 +4237,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4216,13 +4246,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint32Only, opStructFieldHeadOmitEmptyUint32Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := uint64(e.ptrToUint32(p)) + v := uint64(ptrToUint32(p)) if v != 0 { b = append(b, code.key...) b = appendUint(b, v) @@ -4234,12 +4264,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint32Ptr: p := load(ctxptr, code.idx) @@ -4251,17 +4281,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint32Ptr: p := load(ctxptr, code.idx) @@ -4271,16 +4301,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint32Ptr: p := load(ctxptr, code.idx) @@ -4292,12 +4322,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } } @@ -4311,7 +4341,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4320,7 +4350,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeComma(b) code = code.next @@ -4332,14 +4362,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint32PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = encodeComma(b) } code = code.next @@ -4351,7 +4381,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4361,7 +4391,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -4377,18 +4407,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint32: ptr := load(ctxptr, code.idx) @@ -4396,14 +4426,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32: @@ -4411,7 +4441,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4424,7 +4454,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint32: @@ -4434,7 +4464,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4445,7 +4475,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -4454,7 +4484,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4471,13 +4501,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint32Ptr: p := load(ctxptr, code.idx) @@ -4486,16 +4516,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32Ptr: p := load(ctxptr, code.idx) @@ -4503,17 +4533,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint32Ptr: p := load(ctxptr, code.idx) @@ -4522,12 +4552,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -4538,7 +4568,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4546,7 +4576,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeComma(b) code = code.next @@ -4556,7 +4586,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4564,7 +4594,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = encodeComma(b) code = code.next } @@ -4574,7 +4604,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4583,13 +4613,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint64: ptr := load(ctxptr, code.idx) @@ -4600,14 +4630,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint64: @@ -4618,7 +4648,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4631,7 +4661,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint64: @@ -4644,7 +4674,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4653,13 +4683,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint64Only, opStructFieldHeadOmitEmptyUint64Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToUint64(p) + v := ptrToUint64(p) if v != 0 { b = append(b, code.key...) b = appendUint(b, v) @@ -4671,12 +4701,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint64Ptr: p := load(ctxptr, code.idx) @@ -4688,17 +4718,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint64Ptr: p := load(ctxptr, code.idx) @@ -4708,16 +4738,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint64Ptr: p := load(ctxptr, code.idx) @@ -4729,12 +4759,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } } @@ -4748,7 +4778,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint64PtrOnly: p := load(ctxptr, code.idx) @@ -4757,7 +4787,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeComma(b) code = code.next @@ -4769,14 +4799,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint64PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = encodeComma(b) } code = code.next @@ -4788,7 +4818,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) @@ -4798,7 +4828,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -4814,18 +4844,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint64: ptr := load(ctxptr, code.idx) @@ -4833,14 +4863,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64: @@ -4848,7 +4878,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4861,7 +4891,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint64: @@ -4871,7 +4901,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4882,7 +4912,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -4891,7 +4921,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4908,13 +4938,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint64Ptr: p := load(ctxptr, code.idx) @@ -4923,16 +4953,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64Ptr: p := load(ctxptr, code.idx) @@ -4940,17 +4970,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint64Ptr: p := load(ctxptr, code.idx) @@ -4959,12 +4989,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -4975,7 +5005,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint64PtrOnly: p := load(ctxptr, code.idx) @@ -4983,7 +5013,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeComma(b) code = code.next @@ -4993,7 +5023,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64PtrOnly: p := load(ctxptr, code.idx) @@ -5001,7 +5031,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = encodeComma(b) code = code.next } @@ -5011,7 +5041,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) @@ -5020,13 +5050,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat32: ptr := load(ctxptr, code.idx) @@ -5037,14 +5067,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyFloat32: @@ -5055,7 +5085,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -5068,7 +5098,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagFloat32: @@ -5081,7 +5111,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -5090,13 +5120,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat32Only, opStructFieldHeadOmitEmptyFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToFloat32(p) + v := ptrToFloat32(p) if v != 0 { b = append(b, code.key...) b = encodeFloat32(b, v) @@ -5108,12 +5138,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat32Ptr: p := load(ctxptr, code.idx) @@ -5125,17 +5155,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyFloat32Ptr: p := load(ctxptr, code.idx) @@ -5145,16 +5175,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagFloat32Ptr: p := load(ctxptr, code.idx) @@ -5166,12 +5196,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } } @@ -5185,7 +5215,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5194,7 +5224,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } b = encodeComma(b) code = code.next @@ -5206,14 +5236,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyFloat32PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = encodeComma(b) } code = code.next @@ -5225,7 +5255,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5235,7 +5265,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -5251,18 +5281,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat32: ptr := load(ctxptr, code.idx) @@ -5270,14 +5300,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32: @@ -5285,7 +5315,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -5298,7 +5328,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagFloat32: @@ -5308,7 +5338,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -5319,7 +5349,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -5328,7 +5358,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -5345,13 +5375,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat32Ptr: p := load(ctxptr, code.idx) @@ -5360,16 +5390,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32Ptr: p := load(ctxptr, code.idx) @@ -5377,17 +5407,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat32Ptr: p := load(ctxptr, code.idx) @@ -5396,12 +5426,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -5412,7 +5442,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5420,7 +5450,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } b = encodeComma(b) code = code.next @@ -5430,7 +5460,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5438,7 +5468,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = encodeComma(b) code = code.next } @@ -5448,7 +5478,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5457,13 +5487,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat64: ptr := load(ctxptr, code.idx) @@ -5472,7 +5502,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeComma(b) code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5485,7 +5515,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadOmitEmptyFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyFloat64: @@ -5496,7 +5526,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -5512,7 +5542,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagFloat64: @@ -5523,7 +5553,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5538,7 +5568,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5548,7 +5578,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadOmitEmptyFloat64Only, opStructFieldHeadOmitEmptyFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if v != 0 { if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) @@ -5563,7 +5593,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5572,7 +5602,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeComma(b) code = code.next case opStructFieldPtrHeadFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat64Ptr: p := load(ctxptr, code.idx) @@ -5584,11 +5614,11 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5598,7 +5628,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyFloat64Ptr: p := load(ctxptr, code.idx) @@ -5608,10 +5638,10 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5621,7 +5651,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next } case opStructFieldPtrHeadStringTagFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagFloat64Ptr: p := load(ctxptr, code.idx) @@ -5633,12 +5663,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5656,7 +5686,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5665,7 +5695,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5681,14 +5711,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyFloat64PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5704,7 +5734,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5714,7 +5744,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5734,12 +5764,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5749,14 +5779,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5768,7 +5798,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadOmitEmptyFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64: @@ -5776,12 +5806,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v == 0 { code = code.nextField } else { b = append(b, code.key...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5793,7 +5823,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagFloat64: @@ -5803,7 +5833,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5818,7 +5848,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5831,12 +5861,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v == 0 { code = code.nextField } else { b = append(b, code.key...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5852,7 +5882,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5862,7 +5892,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next } case opStructFieldPtrAnonymousHeadFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat64Ptr: p := load(ctxptr, code.idx) @@ -5871,11 +5901,11 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5884,7 +5914,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64Ptr: p := load(ctxptr, code.idx) @@ -5892,12 +5922,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5906,7 +5936,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next } case opStructFieldPtrAnonymousHeadStringTagFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat64Ptr: p := load(ctxptr, code.idx) @@ -5915,12 +5945,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5935,7 +5965,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5943,7 +5973,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5957,7 +5987,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5965,7 +5995,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5979,7 +6009,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5988,7 +6018,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5998,7 +6028,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = encodeComma(b) code = code.next case opStructFieldPtrHeadString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadString: ptr := load(ctxptr, code.idx) @@ -6009,14 +6039,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyString: @@ -6027,7 +6057,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { @@ -6040,7 +6070,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagString: @@ -6052,7 +6082,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, s))) b = encodeComma(b) code = code.next @@ -6061,13 +6091,13 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyStringOnly, opStructFieldHeadOmitEmptyStringOnly: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToString(p) + v := ptrToString(p) if v != "" { b = append(b, code.key...) b = encodeNoEscapedString(b, v) @@ -6078,11 +6108,11 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringPtr: p := load(ctxptr, code.idx) @@ -6094,17 +6124,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyStringPtr: p := load(ctxptr, code.idx) @@ -6114,16 +6144,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagStringPtr: p := load(ctxptr, code.idx) @@ -6135,11 +6165,11 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) } } b = encodeComma(b) @@ -6152,7 +6182,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringPtrOnly: p := load(ctxptr, code.idx) @@ -6161,7 +6191,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } b = encodeComma(b) code = code.next @@ -6173,14 +6203,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyStringPtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) b = encodeComma(b) } code = code.next @@ -6192,7 +6222,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) @@ -6201,7 +6231,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) } b = encodeComma(b) code = code.next @@ -6216,18 +6246,18 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadString: ptr := load(ctxptr, code.idx) @@ -6235,14 +6265,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyString: @@ -6250,7 +6280,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { @@ -6263,7 +6293,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagString: @@ -6272,7 +6302,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(ptr)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(ptr)))) b = encodeComma(b) code = code.next } @@ -6282,7 +6312,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -6291,7 +6321,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { @@ -6307,12 +6337,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(ptr)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(ptr)))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringPtr: p := load(ctxptr, code.idx) @@ -6321,16 +6351,16 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyStringPtr: p := load(ctxptr, code.idx) @@ -6338,17 +6368,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagStringPtr: p := load(ctxptr, code.idx) @@ -6357,11 +6387,11 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( break } b = append(b, code.key...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) } b = encodeComma(b) code = code.next @@ -6371,7 +6401,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringPtrOnly: p := load(ctxptr, code.idx) @@ -6379,7 +6409,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } b = encodeComma(b) code = code.next @@ -6389,7 +6419,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyStringPtrOnly: p := load(ctxptr, code.idx) @@ -6397,7 +6427,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.nextField } else { b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) b = encodeComma(b) code = code.next } @@ -6407,7 +6437,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) @@ -6415,7 +6445,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) } b = encodeComma(b) code = code.next @@ -6427,7 +6457,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadBool: ptr := load(ctxptr, code.idx) @@ -6442,7 +6472,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -6459,11 +6489,11 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.key...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadBool: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadBool: ptr := load(ctxptr, code.idx) @@ -6471,7 +6501,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -6483,7 +6513,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadBytes: ptr := load(ctxptr, code.idx) @@ -6498,12 +6528,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadBytes: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadBytes: ptr := load(ctxptr, code.idx) @@ -6511,7 +6541,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -6523,7 +6553,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadArray: ptr := load(ctxptr, code.idx) + code.offset @@ -6544,7 +6574,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( store(ctxptr, code.idx, ptr) } case opStructFieldPtrAnonymousHeadArray: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadArray: ptr := load(ctxptr, code.idx) + code.offset @@ -6563,7 +6593,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadSlice: ptr := load(ctxptr, code.idx) @@ -6585,7 +6615,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( store(ctxptr, code.idx, p) } case opStructFieldPtrAnonymousHeadSlice: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadSlice: ptr := load(ctxptr, code.idx) @@ -6605,7 +6635,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadMarshalJSON: ptr := load(ctxptr, code.idx) @@ -6617,7 +6647,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) ptr += code.offset - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) rv := reflect.ValueOf(v) if rv.Type().Kind() == reflect.Interface && rv.IsNil() { b = encodeNull(b) @@ -6644,7 +6674,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next } case opStructFieldPtrAnonymousHeadMarshalJSON: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadMarshalJSON: ptr := load(ctxptr, code.idx) @@ -6653,7 +6683,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) ptr += code.offset - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) rv := reflect.ValueOf(v) if rv.Type().Kind() == reflect.Interface && rv.IsNil() { b = encodeNull(b) @@ -6687,7 +6717,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadMarshalText: ptr := load(ctxptr, code.idx) @@ -6699,7 +6729,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) ptr += code.offset - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) rv := reflect.ValueOf(v) if rv.Type().Kind() == reflect.Interface && rv.IsNil() { b = encodeNull(b) @@ -6716,7 +6746,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next } case opStructFieldPtrAnonymousHeadMarshalText: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadMarshalText: ptr := load(ctxptr, code.idx) @@ -6725,7 +6755,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) ptr += code.offset - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) rv := reflect.ValueOf(v) if rv.Type().Kind() == reflect.Interface && rv.IsNil() { b = encodeNull(b) @@ -6744,7 +6774,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyBool: @@ -6755,7 +6785,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if !v { code = code.nextField } else { @@ -6768,7 +6798,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyBool: @@ -6776,7 +6806,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if !v { code = code.nextField } else { @@ -6789,7 +6819,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyBytes: @@ -6800,7 +6830,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, '{') - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) == 0 { code = code.nextField } else { @@ -6813,7 +6843,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyBytes: @@ -6821,7 +6851,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( if ptr == 0 { code = code.end.next } else { - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) == 0 { code = code.nextField } else { @@ -6834,7 +6864,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadOmitEmptyMarshalJSON: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyMarshalJSON: @@ -6846,7 +6876,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr if p == nil || (!isPtr && *(*unsafe.Pointer)(p) == nil) { code = code.nextField @@ -6883,7 +6913,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadOmitEmptyMarshalJSON: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyMarshalJSON: @@ -6892,7 +6922,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr if p == nil || (!isPtr && *(*unsafe.Pointer)(p) == nil) { code = code.nextField @@ -6929,7 +6959,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadOmitEmptyMarshalText: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyMarshalText: @@ -6941,7 +6971,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr if p == nil || (!isPtr && *(*unsafe.Pointer)(p) == nil) { code = code.nextField @@ -6963,7 +6993,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadOmitEmptyMarshalText: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyMarshalText: @@ -6972,7 +7002,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr if p == nil || (!isPtr && *(*unsafe.Pointer)(p) == nil) { code = code.nextField @@ -6994,7 +7024,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTag: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTag: @@ -7013,7 +7043,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTag: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTag: @@ -7028,7 +7058,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagBool: @@ -7041,7 +7071,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( b = append(b, '{') b = append(b, code.key...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -7049,7 +7079,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagBool: @@ -7059,7 +7089,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, code.key...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -7067,7 +7097,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagBytes: @@ -7079,14 +7109,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') b = append(b, code.key...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagBytes: @@ -7095,14 +7125,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { b = append(b, code.key...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadStringTagMarshalJSON: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagMarshalJSON: @@ -7114,7 +7144,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr v := *(*interface{})(unsafe.Pointer(&interfaceHeader{typ: code.typ, ptr: p})) bb, err := v.(Marshaler).MarshalJSON() @@ -7149,7 +7179,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagMarshalJSON: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagMarshalJSON: @@ -7158,7 +7188,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr v := *(*interface{})(unsafe.Pointer(&interfaceHeader{typ: code.typ, ptr: p})) bb, err := v.(Marshaler).MarshalJSON() @@ -7193,7 +7223,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrHeadStringTagMarshalText: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagMarshalText: @@ -7205,7 +7235,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( } else { b = append(b, '{') ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) v := *(*interface{})(unsafe.Pointer(&interfaceHeader{typ: code.typ, ptr: p})) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { @@ -7222,7 +7252,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldPtrAnonymousHeadStringTagMarshalText: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagMarshalText: @@ -7231,7 +7261,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.end.next } else { ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) v := *(*interface{})(unsafe.Pointer(&interfaceHeader{typ: code.typ, ptr: p})) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { @@ -7268,12 +7298,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldInt: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, int64(v)) @@ -7284,47 +7314,47 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldIntPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } b = encodeComma(b) code = code.next case opStructFieldIntNPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } b = encodeComma(b) code = code.next case opStructFieldInt8: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, int64(v)) @@ -7335,30 +7365,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldInt8Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) } b = encodeComma(b) code = code.next case opStructFieldInt16: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, int64(v)) @@ -7369,30 +7399,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldInt16Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) } b = encodeComma(b) code = code.next case opStructFieldInt32: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, int64(v)) @@ -7403,30 +7433,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldInt32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) } b = encodeComma(b) code = code.next case opStructFieldInt64: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, v) @@ -7437,30 +7467,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldInt64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) } b = encodeComma(b) code = code.next case opStructFieldUint: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, uint64(v)) @@ -7471,30 +7501,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUintPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) } b = encodeComma(b) code = code.next case opStructFieldUint8: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, uint64(v)) @@ -7505,30 +7535,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUint8Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) } b = encodeComma(b) code = code.next case opStructFieldUint16: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, uint64(v)) @@ -7539,30 +7569,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUint16Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) } b = encodeComma(b) code = code.next case opStructFieldUint32: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, uint64(v)) @@ -7573,30 +7603,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUint32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) } b = encodeComma(b) code = code.next case opStructFieldUint64: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, v) @@ -7607,30 +7637,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint64(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint64(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUint64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) } b = encodeComma(b) code = code.next case opStructFieldFloat32: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyFloat32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = encodeFloat32(b, v) @@ -7641,25 +7671,25 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldFloat32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = encodeComma(b) code = code.next case opStructFieldFloat64: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -7668,7 +7698,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next case opStructFieldOmitEmptyFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v != 0 { if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) @@ -7680,7 +7710,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next case opStructFieldStringTagFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -7693,14 +7723,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldFloat64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) b = encodeComma(b) code = code.next break } - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -7710,12 +7740,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldString: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyString: ptr := load(ctxptr, code.headIdx) - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v != "" { b = append(b, code.key...) b = encodeNoEscapedString(b, v) @@ -7725,50 +7755,50 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldStringTagString: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, s))) b = encodeComma(b) code = code.next case opStructFieldStringPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) } b = encodeComma(b) code = code.next case opStructFieldOmitEmptyStringPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeComma(b) } code = code.next case opStructFieldStringTagStringPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) } b = encodeComma(b) code = code.next case opStructFieldBool: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyBool: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if v { b = append(b, code.key...) b = encodeBool(b, v) @@ -7779,30 +7809,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldBoolPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeBool(b, e.ptrToBool(p)) + b = encodeBool(b, ptrToBool(p)) } b = encodeComma(b) code = code.next case opStructFieldBytes: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) > 0 { b = append(b, code.key...) b = encodeByteSlice(b, v) @@ -7811,7 +7841,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next case opStructFieldStringTagBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) b = append(b, code.key...) b = encodeByteSlice(b, v) b = encodeComma(b) @@ -7820,7 +7850,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -7836,7 +7866,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -7853,9 +7883,9 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) p := ptr + code.offset if code.typ.Kind() == reflect.Ptr && code.typ.Elem().Implements(marshalJSONType) { - p = e.ptrToPtr(p) + p = ptrToPtr(p) } - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) if v != nil && p != 0 { bb, err := v.(Marshaler).MarshalJSON() if err != nil { @@ -7875,7 +7905,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -7886,7 +7916,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldStringTagMarshalText: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -7898,7 +7928,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldOmitEmptyMarshalText: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) if v != nil { bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { @@ -7918,7 +7948,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldOmitEmptyArray: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - array := e.ptrToSlice(p) + array := ptrToSlice(p) if p == 0 || uintptr(array.data) == 0 { code = code.nextField } else { @@ -7935,7 +7965,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructFieldOmitEmptySlice: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) if p == 0 || uintptr(slice.data) == 0 { code = code.nextField } else { @@ -8005,12 +8035,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndInt: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, int64(v)) @@ -8029,27 +8059,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndIntPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyIntPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8064,12 +8094,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagIntPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8077,29 +8107,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndIntNPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } b = appendStructEnd(b) code = code.next case opStructEndInt8: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, int64(v)) @@ -8118,27 +8148,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndInt8Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt8Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8153,12 +8183,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagInt8Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8166,29 +8196,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndInt8NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) } b = appendStructEnd(b) code = code.next case opStructEndInt16: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, int64(v)) @@ -8207,27 +8237,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndInt16Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt16Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8242,12 +8272,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagInt16Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8255,29 +8285,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndInt16NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) } b = appendStructEnd(b) code = code.next case opStructEndInt32: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, int64(v)) @@ -8296,27 +8326,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndInt32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8331,12 +8361,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagInt32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8344,29 +8374,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndInt32NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) } b = appendStructEnd(b) code = code.next case opStructEndInt64: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendInt(b, v) @@ -8385,27 +8415,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndInt64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8420,12 +8450,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagInt64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = append(b, '"') } b = appendStructEnd(b) @@ -8433,29 +8463,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndInt64NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) } b = appendStructEnd(b) code = code.next case opStructEndUint: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, uint64(v)) @@ -8474,27 +8504,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUintPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUintPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8509,12 +8539,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagUintPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8522,29 +8552,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndUintNPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) } b = appendStructEnd(b) code = code.next case opStructEndUint8: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, uint64(v)) @@ -8563,27 +8593,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUint8Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint8Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8598,12 +8628,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagUint8Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8611,29 +8641,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndUint8NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) } b = appendStructEnd(b) code = code.next case opStructEndUint16: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, uint64(v)) @@ -8652,27 +8682,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUint16Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint16Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8687,12 +8717,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagUint16Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8700,29 +8730,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndUint16NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) } b = appendStructEnd(b) code = code.next case opStructEndUint32: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, uint64(v)) @@ -8741,27 +8771,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUint32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8776,12 +8806,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagUint32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8789,29 +8819,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndUint32NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) } b = appendStructEnd(b) code = code.next case opStructEndUint64: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = appendUint(b, v) @@ -8830,27 +8860,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUint64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8865,12 +8895,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagUint64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = append(b, '"') } b = appendStructEnd(b) @@ -8878,29 +8908,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndUint64NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) } b = appendStructEnd(b) code = code.next case opStructEndFloat32: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyFloat32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v != 0 { b = append(b, code.key...) b = encodeFloat32(b, v) @@ -8919,27 +8949,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndFloat32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyFloat32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8954,12 +8984,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagFloat32Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = append(b, '"') } b = appendStructEnd(b) @@ -8967,24 +8997,24 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndFloat32NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = appendStructEnd(b) code = code.next case opStructEndFloat64: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -8993,7 +9023,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next case opStructEndOmitEmptyFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v != 0 { if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) @@ -9013,7 +9043,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next case opStructEndStringTagFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9026,14 +9056,14 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndFloat64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) b = appendStructEnd(b) code = code.next break } - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9042,10 +9072,10 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next case opStructEndOmitEmptyFloat64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9064,12 +9094,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagFloat64Ptr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9081,17 +9111,17 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndFloat64NPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9102,12 +9132,12 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndString: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyString: ptr := load(ctxptr, code.headIdx) - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v != "" { b = append(b, code.key...) b = encodeNoEscapedString(b, v) @@ -9125,27 +9155,27 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagString: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, s))) b = appendStructEnd(b) code = code.next case opStructEndStringPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyStringPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.key...) - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -9160,11 +9190,11 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagStringPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToString(p) + v := ptrToString(p) b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, v))) } b = appendStructEnd(b) @@ -9172,29 +9202,29 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringNPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) } b = appendStructEnd(b) code = code.next case opStructEndBool: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyBool: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if v { b = append(b, code.key...) b = encodeBool(b, v) @@ -9213,30 +9243,30 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndBoolPtr: b = append(b, code.key...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeBool(b, e.ptrToBool(p)) + b = encodeBool(b, ptrToBool(p)) } b = appendStructEnd(b) code = code.next case opStructEndBytes: ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) > 0 { b = append(b, code.key...) b = encodeByteSlice(b, v) @@ -9253,7 +9283,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( code = code.next case opStructEndStringTagBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) b = append(b, code.key...) b = encodeByteSlice(b, v) b = appendStructEnd(b) @@ -9262,7 +9292,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9278,8 +9308,8 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndOmitEmptyMarshalJSON: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) - if v != nil && (code.typ.Kind() != reflect.Ptr || e.ptrToPtr(p) != 0) { + v := ptrToInterface(code, p) + if v != nil && (code.typ.Kind() != reflect.Ptr || ptrToPtr(p) != 0) { bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9305,7 +9335,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9322,7 +9352,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( ptr := load(ctxptr, code.headIdx) b = append(b, code.key...) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -9333,7 +9363,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndOmitEmptyMarshalText: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) if v != nil { bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { @@ -9355,7 +9385,7 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( case opStructEndStringTagMarshalText: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -9371,33 +9401,3 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ( END: return b, nil } - -func (e *Encoder) ptrToInt(p uintptr) int { return **(**int)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToInt8(p uintptr) int8 { return **(**int8)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToInt16(p uintptr) int16 { return **(**int16)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToInt32(p uintptr) int32 { return **(**int32)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToInt64(p uintptr) int64 { return **(**int64)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToUint(p uintptr) uint { return **(**uint)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToUint8(p uintptr) uint8 { return **(**uint8)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToUint16(p uintptr) uint16 { return **(**uint16)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToUint32(p uintptr) uint32 { return **(**uint32)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToUint64(p uintptr) uint64 { return **(**uint64)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToFloat32(p uintptr) float32 { return **(**float32)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToFloat64(p uintptr) float64 { return **(**float64)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToBool(p uintptr) bool { return **(**bool)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToByte(p uintptr) byte { return **(**byte)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToBytes(p uintptr) []byte { return **(**[]byte)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToString(p uintptr) string { return **(**string)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToSlice(p uintptr) *sliceHeader { return *(**sliceHeader)(unsafe.Pointer(&p)) } -func (e *Encoder) ptrToPtr(p uintptr) uintptr { - return uintptr(**(**unsafe.Pointer)(unsafe.Pointer(&p))) -} -func (e *Encoder) ptrToUnsafePtr(p uintptr) unsafe.Pointer { - return *(*unsafe.Pointer)(unsafe.Pointer(&p)) -} -func (e *Encoder) ptrToInterface(code *opcode, p uintptr) interface{} { - return *(*interface{})(unsafe.Pointer(&interfaceHeader{ - typ: code.typ, - ptr: *(*unsafe.Pointer)(unsafe.Pointer(&p)), - })) -} diff --git a/encode_vm_escaped.go b/encode_vm_escaped.go index 78cd64e..2d3e51a 100644 --- a/encode_vm_escaped.go +++ b/encode_vm_escaped.go @@ -11,7 +11,7 @@ import ( "unsafe" ) -func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ([]byte, error) { +func encodeRunEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, opt EncodeOption) ([]byte, error) { recursiveLevel := 0 ptrOffset := uintptr(0) ctxptr := ctx.ptr() @@ -25,113 +25,113 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opPtr: ptr := load(ctxptr, code.idx) code = code.next - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) case opInt: - b = appendInt(b, int64(e.ptrToInt(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opInt8: - b = appendInt(b, int64(e.ptrToInt8(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt8(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opInt16: - b = appendInt(b, int64(e.ptrToInt16(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt16(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opInt32: - b = appendInt(b, int64(e.ptrToInt32(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt32(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opInt64: - b = appendInt(b, e.ptrToInt64(load(ctxptr, code.idx))) + b = appendInt(b, ptrToInt64(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opUint: - b = appendUint(b, uint64(e.ptrToUint(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opUint8: - b = appendUint(b, uint64(e.ptrToUint8(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint8(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opUint16: - b = appendUint(b, uint64(e.ptrToUint16(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint16(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opUint32: - b = appendUint(b, uint64(e.ptrToUint32(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint32(load(ctxptr, code.idx)))) b = encodeComma(b) code = code.next case opUint64: - b = appendUint(b, e.ptrToUint64(load(ctxptr, code.idx))) + b = appendUint(b, ptrToUint64(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opIntString: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opInt8String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt8(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opInt16String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt16(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opInt32String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt32(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opInt64String: b = append(b, '"') - b = appendInt(b, e.ptrToInt64(load(ctxptr, code.idx))) + b = appendInt(b, ptrToInt64(load(ctxptr, code.idx))) b = append(b, '"') b = encodeComma(b) code = code.next case opUintString: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opUint8String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint8(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opUint16String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint16(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opUint32String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint32(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeComma(b) code = code.next case opUint64String: b = append(b, '"') - b = appendUint(b, e.ptrToUint64(load(ctxptr, code.idx))) + b = appendUint(b, ptrToUint64(load(ctxptr, code.idx))) b = append(b, '"') b = encodeComma(b) code = code.next case opFloat32: - b = encodeFloat32(b, e.ptrToFloat32(load(ctxptr, code.idx))) + b = encodeFloat32(b, ptrToFloat32(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opFloat64: - v := e.ptrToFloat64(load(ctxptr, code.idx)) + v := ptrToFloat64(load(ctxptr, code.idx)) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -139,20 +139,20 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeComma(b) code = code.next case opString: - b = encodeEscapedString(b, e.ptrToString(load(ctxptr, code.idx))) + b = encodeEscapedString(b, ptrToString(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opBool: - b = encodeBool(b, e.ptrToBool(load(ctxptr, code.idx))) + b = encodeBool(b, ptrToBool(load(ctxptr, code.idx))) b = encodeComma(b) code = code.next case opBytes: ptr := load(ctxptr, code.idx) - slice := e.ptrToSlice(ptr) + slice := ptrToSlice(ptr) if ptr == 0 || uintptr(slice.data) == 0 { b = encodeNull(b) } else { - b = encodeByteSlice(b, e.ptrToBytes(ptr)) + b = encodeByteSlice(b, ptrToBytes(ptr)) } b = encodeComma(b) code = code.next @@ -170,7 +170,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } } ctx.seenPtr = append(ctx.seenPtr, ptr) - iface := (*interfaceHeader)(e.ptrToUnsafePtr(ptr)) + iface := (*interfaceHeader)(ptrToUnsafePtr(ptr)) if iface == nil || iface.ptr == nil { b = encodeNull(b) b = encodeComma(b) @@ -178,7 +178,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(iface)) - ifaceCodeSet, err := e.compileToGetCodeSet(uintptr(unsafe.Pointer(iface.typ))) + ifaceCodeSet, err := encodeCompileToGetCodeSet(uintptr(unsafe.Pointer(iface.typ))) if err != nil { return nil, err } @@ -200,7 +200,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ctx.ptrs = newPtrs - bb, err := e.runEscaped(ctx, b, ifaceCodeSet) + bb, err := encodeRunEscaped(ctx, b, ifaceCodeSet, opt) if err != nil { return nil, err } @@ -219,7 +219,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next break } - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -241,7 +241,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opMarshalText: ptr := load(ctxptr, code.idx) isPtr := code.typ.Kind() == reflect.Ptr - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) if p == nil || isPtr && *(*unsafe.Pointer)(p) == nil { b = append(b, '"', '"', ',') } else { @@ -259,7 +259,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next case opSliceHead: p := load(ctxptr, code.idx) - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) if p == 0 || uintptr(slice.data) == 0 { b = encodeNull(b) b = encodeComma(b) @@ -332,7 +332,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeComma(b) code = code.end.next } else { - uptr := e.ptrToUnsafePtr(ptr) + uptr := ptrToUnsafePtr(ptr) mlen := maplen(uptr) if mlen > 0 { b = append(b, '{') @@ -341,7 +341,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod store(ctxptr, code.elemIdx, 0) store(ctxptr, code.length, uintptr(mlen)) store(ctxptr, code.mapIter, uintptr(iter)) - if !e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) == 0 { mapCtx := newMapContext(mlen) mapCtx.pos = append(mapCtx.pos, len(b)) ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) @@ -363,8 +363,8 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { // load pointer - ptr = e.ptrToPtr(ptr) - uptr := e.ptrToUnsafePtr(ptr) + ptr = ptrToPtr(ptr) + uptr := ptrToUnsafePtr(ptr) if ptr == 0 { b = encodeNull(b) b = encodeComma(b) @@ -381,9 +381,10 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod store(ctxptr, code.mapIter, uintptr(iter)) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) - if !e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) == 0 { mapCtx := newMapContext(mlen) mapCtx.pos = append(mapCtx.pos, len(b)) + ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } code = code.next @@ -396,10 +397,10 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod idx := load(ctxptr, code.elemIdx) length := load(ctxptr, code.length) idx++ - if e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) != 0 { if idx < length { ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) store(ctxptr, code.elemIdx, idx) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) @@ -412,11 +413,11 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } } else { ptr := load(ctxptr, code.end.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) mapCtx.pos = append(mapCtx.pos, len(b)) if idx < length { ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) store(ctxptr, code.elemIdx, idx) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) @@ -426,16 +427,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } } case opMapValue: - if e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) != 0 { last := len(b) - 1 b[last] = ':' } else { ptr := load(ctxptr, code.end.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) mapCtx.pos = append(mapCtx.pos, len(b)) } ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) value := mapitervalue(iter) store(ctxptr, code.next.idx, uintptr(value)) mapiternext(iter) @@ -444,7 +445,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod // this operation only used by sorted map. length := int(load(ctxptr, code.length)) ptr := load(ctxptr, code.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) pos := mapCtx.pos for i := 0; i < length; i++ { startKey := pos[i*2] @@ -475,7 +476,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod releaseMapContext(mapCtx) code = code.next case opStructFieldPtrAnonymousHeadRecursive: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadRecursive: fallthrough @@ -516,7 +517,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ctx.seenPtr = ctx.seenPtr[:len(ctx.seenPtr)-1] codePtr := load(ctxptr, code.elemIdx) - code = (*opcode)(e.ptrToUnsafePtr(codePtr)) + code = (*opcode)(ptrToUnsafePtr(codePtr)) ctxptr = ctx.ptr() + offset ptrOffset = offset case opStructFieldPtrHead: @@ -526,7 +527,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHead: ptr := load(ctxptr, code.idx) @@ -546,7 +547,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmpty: @@ -597,7 +598,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmpty: @@ -615,7 +616,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } } case opStructFieldPtrHeadInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt: ptr := load(ctxptr, code.idx) @@ -626,14 +627,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt: @@ -644,7 +645,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -657,7 +658,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt: @@ -670,7 +671,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -679,13 +680,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyIntOnly, opStructFieldHeadOmitEmptyIntOnly: p := load(ctxptr, code.idx) b = append(b, '{') - v := int64(e.ptrToInt(p)) + v := int64(ptrToInt(p)) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, v) @@ -697,12 +698,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadIntPtr: p := load(ctxptr, code.idx) @@ -714,17 +715,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyIntPtr: p := load(ctxptr, code.idx) @@ -734,16 +735,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagIntPtr: p := load(ctxptr, code.idx) @@ -755,12 +756,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } } @@ -774,7 +775,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadIntPtrOnly: p := load(ctxptr, code.idx) @@ -783,7 +784,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeComma(b) code = code.next @@ -795,14 +796,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyIntPtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = encodeComma(b) } code = code.next @@ -814,7 +815,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) @@ -824,7 +825,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -840,18 +841,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt: ptr := load(ctxptr, code.idx) @@ -859,14 +860,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt: @@ -874,7 +875,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -887,7 +888,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt: @@ -897,7 +898,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -908,7 +909,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -917,7 +918,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -934,13 +935,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadIntPtr: p := load(ctxptr, code.idx) @@ -949,16 +950,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyIntPtr: p := load(ctxptr, code.idx) @@ -966,17 +967,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagIntPtr: p := load(ctxptr, code.idx) @@ -985,12 +986,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1001,7 +1002,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadIntPtrOnly: p := load(ctxptr, code.idx) @@ -1009,7 +1010,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1019,7 +1020,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyIntPtrOnly: p := load(ctxptr, code.idx) @@ -1027,7 +1028,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = encodeComma(b) code = code.next } @@ -1037,7 +1038,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) @@ -1046,13 +1047,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt8: ptr := load(ctxptr, code.idx) @@ -1063,14 +1064,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt8: @@ -1081,7 +1082,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1094,7 +1095,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt8: @@ -1107,7 +1108,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1116,13 +1117,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt8Only, opStructFieldHeadOmitEmptyInt8Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := int64(e.ptrToInt8(p)) + v := int64(ptrToInt8(p)) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, v) @@ -1134,12 +1135,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt8Ptr: p := load(ctxptr, code.idx) @@ -1151,17 +1152,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt8Ptr: p := load(ctxptr, code.idx) @@ -1171,16 +1172,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt8Ptr: p := load(ctxptr, code.idx) @@ -1192,12 +1193,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } } @@ -1211,7 +1212,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1220,7 +1221,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1232,14 +1233,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt8PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = encodeComma(b) } code = code.next @@ -1251,7 +1252,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1261,7 +1262,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1277,18 +1278,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt8: ptr := load(ctxptr, code.idx) @@ -1296,14 +1297,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8: @@ -1311,7 +1312,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1324,7 +1325,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt8: @@ -1334,7 +1335,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1345,7 +1346,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -1354,7 +1355,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1371,13 +1372,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt8Ptr: p := load(ctxptr, code.idx) @@ -1386,16 +1387,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8Ptr: p := load(ctxptr, code.idx) @@ -1403,17 +1404,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt8Ptr: p := load(ctxptr, code.idx) @@ -1422,12 +1423,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1438,7 +1439,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1446,7 +1447,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1456,7 +1457,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1464,7 +1465,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = encodeComma(b) code = code.next } @@ -1474,7 +1475,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) @@ -1483,13 +1484,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt16: ptr := load(ctxptr, code.idx) @@ -1500,14 +1501,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt16: @@ -1518,7 +1519,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1531,7 +1532,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt16: @@ -1544,7 +1545,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1553,13 +1554,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt16Only, opStructFieldHeadOmitEmptyInt16Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := int64(e.ptrToInt16(p)) + v := int64(ptrToInt16(p)) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, v) @@ -1571,12 +1572,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt16Ptr: p := load(ctxptr, code.idx) @@ -1588,17 +1589,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt16Ptr: p := load(ctxptr, code.idx) @@ -1608,16 +1609,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt16Ptr: p := load(ctxptr, code.idx) @@ -1629,12 +1630,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } } @@ -1648,7 +1649,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1657,7 +1658,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1669,14 +1670,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt16PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = encodeComma(b) } code = code.next @@ -1688,7 +1689,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1698,7 +1699,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1714,18 +1715,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt16: ptr := load(ctxptr, code.idx) @@ -1733,14 +1734,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16: @@ -1748,7 +1749,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1761,7 +1762,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt16: @@ -1771,7 +1772,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1782,7 +1783,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -1791,7 +1792,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1808,13 +1809,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt16Ptr: p := load(ctxptr, code.idx) @@ -1823,16 +1824,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16Ptr: p := load(ctxptr, code.idx) @@ -1840,17 +1841,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt16Ptr: p := load(ctxptr, code.idx) @@ -1859,12 +1860,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -1875,7 +1876,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1883,7 +1884,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeComma(b) code = code.next @@ -1893,7 +1894,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1901,7 +1902,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = encodeComma(b) code = code.next } @@ -1911,7 +1912,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) @@ -1920,13 +1921,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt32: ptr := load(ctxptr, code.idx) @@ -1937,14 +1938,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt32: @@ -1955,7 +1956,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -1968,7 +1969,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt32: @@ -1981,7 +1982,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -1990,13 +1991,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt32Only, opStructFieldHeadOmitEmptyInt32Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := int64(e.ptrToInt32(p)) + v := int64(ptrToInt32(p)) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, v) @@ -2008,12 +2009,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt32Ptr: p := load(ctxptr, code.idx) @@ -2025,17 +2026,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt32Ptr: p := load(ctxptr, code.idx) @@ -2045,16 +2046,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt32Ptr: p := load(ctxptr, code.idx) @@ -2066,12 +2067,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } } @@ -2085,7 +2086,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2094,7 +2095,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeComma(b) code = code.next @@ -2106,14 +2107,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt32PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = encodeComma(b) } code = code.next @@ -2125,7 +2126,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2135,7 +2136,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -2151,18 +2152,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt32: ptr := load(ctxptr, code.idx) @@ -2170,14 +2171,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32: @@ -2185,7 +2186,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2198,7 +2199,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt32: @@ -2208,7 +2209,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2219,7 +2220,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -2228,7 +2229,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2245,13 +2246,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt32Ptr: p := load(ctxptr, code.idx) @@ -2260,16 +2261,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32Ptr: p := load(ctxptr, code.idx) @@ -2277,17 +2278,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt32Ptr: p := load(ctxptr, code.idx) @@ -2296,12 +2297,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -2312,7 +2313,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2320,7 +2321,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeComma(b) code = code.next @@ -2330,7 +2331,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2338,7 +2339,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = encodeComma(b) code = code.next } @@ -2348,7 +2349,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) @@ -2357,13 +2358,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt64: ptr := load(ctxptr, code.idx) @@ -2374,14 +2375,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt64: @@ -2392,7 +2393,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2405,7 +2406,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt64: @@ -2418,7 +2419,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2427,13 +2428,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt64Only, opStructFieldHeadOmitEmptyInt64Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToInt64(p) + v := ptrToInt64(p) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, v) @@ -2445,12 +2446,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt64Ptr: p := load(ctxptr, code.idx) @@ -2462,17 +2463,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt64Ptr: p := load(ctxptr, code.idx) @@ -2482,16 +2483,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt64Ptr: p := load(ctxptr, code.idx) @@ -2503,12 +2504,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } } @@ -2522,7 +2523,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2531,7 +2532,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeComma(b) code = code.next @@ -2543,14 +2544,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt64PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = encodeComma(b) } code = code.next @@ -2562,7 +2563,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2572,7 +2573,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -2588,18 +2589,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt64: ptr := load(ctxptr, code.idx) @@ -2607,14 +2608,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64: @@ -2622,7 +2623,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2635,7 +2636,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagInt64: @@ -2645,7 +2646,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2656,7 +2657,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -2665,7 +2666,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2682,13 +2683,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt64Ptr: p := load(ctxptr, code.idx) @@ -2697,16 +2698,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64Ptr: p := load(ctxptr, code.idx) @@ -2714,17 +2715,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt64Ptr: p := load(ctxptr, code.idx) @@ -2733,12 +2734,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -2749,7 +2750,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2757,7 +2758,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeComma(b) code = code.next @@ -2767,7 +2768,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2775,7 +2776,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = encodeComma(b) code = code.next } @@ -2785,7 +2786,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) @@ -2794,13 +2795,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint: ptr := load(ctxptr, code.idx) @@ -2811,14 +2812,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint: @@ -2829,7 +2830,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -2842,7 +2843,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint: @@ -2855,7 +2856,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -2864,13 +2865,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUintOnly, opStructFieldHeadOmitEmptyUintOnly: p := load(ctxptr, code.idx) b = append(b, '{') - v := uint64(e.ptrToUint(p)) + v := uint64(ptrToUint(p)) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, v) @@ -2882,12 +2883,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUintPtr: p := load(ctxptr, code.idx) @@ -2899,17 +2900,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUintPtr: p := load(ctxptr, code.idx) @@ -2919,16 +2920,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUintPtr: p := load(ctxptr, code.idx) @@ -2940,12 +2941,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } } @@ -2959,7 +2960,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUintPtrOnly: p := load(ctxptr, code.idx) @@ -2968,7 +2969,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeComma(b) code = code.next @@ -2980,14 +2981,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUintPtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = encodeComma(b) } code = code.next @@ -2999,7 +3000,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) @@ -3009,7 +3010,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3025,18 +3026,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint: ptr := load(ctxptr, code.idx) @@ -3044,14 +3045,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint: @@ -3059,7 +3060,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3072,7 +3073,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint: @@ -3082,7 +3083,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3093,7 +3094,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -3102,7 +3103,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3119,13 +3120,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUintPtr: p := load(ctxptr, code.idx) @@ -3134,16 +3135,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUintPtr: p := load(ctxptr, code.idx) @@ -3151,17 +3152,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUintPtr: p := load(ctxptr, code.idx) @@ -3170,12 +3171,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3186,7 +3187,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUintPtrOnly: p := load(ctxptr, code.idx) @@ -3194,7 +3195,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3204,7 +3205,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUintPtrOnly: p := load(ctxptr, code.idx) @@ -3212,7 +3213,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = encodeComma(b) code = code.next } @@ -3222,7 +3223,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) @@ -3231,13 +3232,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint8: ptr := load(ctxptr, code.idx) @@ -3248,14 +3249,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint8: @@ -3266,7 +3267,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3279,7 +3280,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint8: @@ -3292,7 +3293,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3301,13 +3302,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint8Only, opStructFieldHeadOmitEmptyUint8Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := uint64(e.ptrToUint8(p)) + v := uint64(ptrToUint8(p)) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, v) @@ -3319,12 +3320,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint8Ptr: p := load(ctxptr, code.idx) @@ -3336,17 +3337,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint8Ptr: p := load(ctxptr, code.idx) @@ -3356,16 +3357,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint8Ptr: p := load(ctxptr, code.idx) @@ -3377,12 +3378,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } } @@ -3396,7 +3397,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3405,7 +3406,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3417,14 +3418,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint8PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = encodeComma(b) } code = code.next @@ -3436,7 +3437,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3446,7 +3447,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3462,18 +3463,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint8: ptr := load(ctxptr, code.idx) @@ -3481,14 +3482,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8: @@ -3496,7 +3497,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3509,7 +3510,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint8: @@ -3519,7 +3520,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3530,7 +3531,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -3539,7 +3540,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3556,13 +3557,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint8Ptr: p := load(ctxptr, code.idx) @@ -3571,16 +3572,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8Ptr: p := load(ctxptr, code.idx) @@ -3588,17 +3589,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint8Ptr: p := load(ctxptr, code.idx) @@ -3607,12 +3608,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3623,7 +3624,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3631,7 +3632,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3641,7 +3642,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3649,7 +3650,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = encodeComma(b) code = code.next } @@ -3659,7 +3660,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) @@ -3668,13 +3669,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint16: ptr := load(ctxptr, code.idx) @@ -3685,14 +3686,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint16: @@ -3703,7 +3704,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3716,7 +3717,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint16: @@ -3729,7 +3730,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3738,13 +3739,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint16Only, opStructFieldHeadOmitEmptyUint16Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := uint64(e.ptrToUint16(p)) + v := uint64(ptrToUint16(p)) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, v) @@ -3756,12 +3757,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint16Ptr: p := load(ctxptr, code.idx) @@ -3773,17 +3774,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint16Ptr: p := load(ctxptr, code.idx) @@ -3793,16 +3794,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint16Ptr: p := load(ctxptr, code.idx) @@ -3814,12 +3815,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } } @@ -3833,7 +3834,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint16PtrOnly: p := load(ctxptr, code.idx) @@ -3842,7 +3843,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeComma(b) code = code.next @@ -3854,14 +3855,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint16PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = encodeComma(b) } code = code.next @@ -3873,7 +3874,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) @@ -3883,7 +3884,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -3899,18 +3900,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint16: ptr := load(ctxptr, code.idx) @@ -3918,14 +3919,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16: @@ -3933,7 +3934,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3946,7 +3947,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint16: @@ -3956,7 +3957,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -3967,7 +3968,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -3976,7 +3977,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -3993,13 +3994,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint16Ptr: p := load(ctxptr, code.idx) @@ -4008,16 +4009,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16Ptr: p := load(ctxptr, code.idx) @@ -4025,17 +4026,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint16Ptr: p := load(ctxptr, code.idx) @@ -4044,12 +4045,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -4060,7 +4061,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint16PtrOnly: p := load(ctxptr, code.idx) @@ -4068,7 +4069,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeComma(b) code = code.next @@ -4078,7 +4079,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16PtrOnly: p := load(ctxptr, code.idx) @@ -4086,7 +4087,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = encodeComma(b) code = code.next } @@ -4096,7 +4097,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) @@ -4105,13 +4106,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint32: ptr := load(ctxptr, code.idx) @@ -4122,14 +4123,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint32: @@ -4140,7 +4141,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4153,7 +4154,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint32: @@ -4166,7 +4167,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4175,13 +4176,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint32Only, opStructFieldHeadOmitEmptyUint32Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := uint64(e.ptrToUint32(p)) + v := uint64(ptrToUint32(p)) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, v) @@ -4193,12 +4194,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint32Ptr: p := load(ctxptr, code.idx) @@ -4210,17 +4211,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint32Ptr: p := load(ctxptr, code.idx) @@ -4230,16 +4231,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint32Ptr: p := load(ctxptr, code.idx) @@ -4251,12 +4252,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } } @@ -4270,7 +4271,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4279,7 +4280,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeComma(b) code = code.next @@ -4291,14 +4292,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint32PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = encodeComma(b) } code = code.next @@ -4310,7 +4311,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4320,7 +4321,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -4336,18 +4337,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint32: ptr := load(ctxptr, code.idx) @@ -4355,14 +4356,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32: @@ -4370,7 +4371,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4383,7 +4384,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint32: @@ -4393,7 +4394,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4404,7 +4405,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeComma(b) code = code.next } @@ -4413,7 +4414,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4430,13 +4431,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint32Ptr: p := load(ctxptr, code.idx) @@ -4445,16 +4446,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32Ptr: p := load(ctxptr, code.idx) @@ -4462,17 +4463,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint32Ptr: p := load(ctxptr, code.idx) @@ -4481,12 +4482,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) @@ -4497,7 +4498,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4505,7 +4506,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeComma(b) code = code.next @@ -4515,7 +4516,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4523,7 +4524,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = encodeComma(b) code = code.next } @@ -4533,7 +4534,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) @@ -4542,13 +4543,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint64: ptr := load(ctxptr, code.idx) @@ -4559,14 +4560,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint64: @@ -4577,7 +4578,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4590,7 +4591,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint64: @@ -4603,7 +4604,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4612,13 +4613,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint64Only, opStructFieldHeadOmitEmptyUint64Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToUint64(p) + v := ptrToUint64(p) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, v) @@ -4630,12 +4631,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint64Ptr: p := load(ctxptr, code.idx) @@ -4647,17 +4648,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint64Ptr: p := load(ctxptr, code.idx) @@ -4667,16 +4668,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint64Ptr: p := load(ctxptr, code.idx) @@ -4688,12 +4689,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } } @@ -4707,7 +4708,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint64PtrOnly: p := load(ctxptr, code.idx) @@ -4716,7 +4717,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeComma(b) code = code.next @@ -4728,14 +4729,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint64PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = encodeComma(b) } code = code.next @@ -4747,7 +4748,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) @@ -4757,7 +4758,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -4773,18 +4774,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint64: ptr := load(ctxptr, code.idx) @@ -4792,14 +4793,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64: @@ -4807,7 +4808,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4820,7 +4821,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagUint64: @@ -4830,7 +4831,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -4841,7 +4842,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -4850,7 +4851,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -4867,13 +4868,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint64Ptr: p := load(ctxptr, code.idx) @@ -4882,16 +4883,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64Ptr: p := load(ctxptr, code.idx) @@ -4899,17 +4900,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint64Ptr: p := load(ctxptr, code.idx) @@ -4918,12 +4919,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -4934,7 +4935,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint64PtrOnly: p := load(ctxptr, code.idx) @@ -4942,7 +4943,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeComma(b) code = code.next @@ -4952,7 +4953,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64PtrOnly: p := load(ctxptr, code.idx) @@ -4960,7 +4961,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = encodeComma(b) code = code.next } @@ -4970,7 +4971,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) @@ -4979,13 +4980,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat32: ptr := load(ctxptr, code.idx) @@ -4996,14 +4997,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyFloat32: @@ -5014,7 +5015,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -5027,7 +5028,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagFloat32: @@ -5040,7 +5041,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -5049,13 +5050,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat32Only, opStructFieldHeadOmitEmptyFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToFloat32(p) + v := ptrToFloat32(p) if v != 0 { b = append(b, code.escapedKey...) b = encodeFloat32(b, v) @@ -5067,12 +5068,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrHeadFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat32Ptr: p := load(ctxptr, code.idx) @@ -5084,17 +5085,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyFloat32Ptr: p := load(ctxptr, code.idx) @@ -5104,16 +5105,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagFloat32Ptr: p := load(ctxptr, code.idx) @@ -5125,12 +5126,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } } @@ -5144,7 +5145,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5153,7 +5154,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } b = encodeComma(b) code = code.next @@ -5165,14 +5166,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyFloat32PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = encodeComma(b) } code = code.next @@ -5184,7 +5185,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5194,7 +5195,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -5210,18 +5211,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat32: ptr := load(ctxptr, code.idx) @@ -5229,14 +5230,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32: @@ -5244,7 +5245,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -5257,7 +5258,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagFloat32: @@ -5267,7 +5268,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -5278,7 +5279,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -5287,7 +5288,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -5304,13 +5305,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat32Ptr: p := load(ctxptr, code.idx) @@ -5319,16 +5320,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32Ptr: p := load(ctxptr, code.idx) @@ -5336,17 +5337,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat32Ptr: p := load(ctxptr, code.idx) @@ -5355,12 +5356,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeComma(b) @@ -5371,7 +5372,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5379,7 +5380,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) } b = encodeComma(b) code = code.next @@ -5389,7 +5390,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5397,7 +5398,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = encodeComma(b) code = code.next } @@ -5407,7 +5408,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) @@ -5416,13 +5417,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeComma(b) code = code.next case opStructFieldPtrHeadFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat64: ptr := load(ctxptr, code.idx) @@ -5431,7 +5432,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeComma(b) code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5444,7 +5445,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadOmitEmptyFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyFloat64: @@ -5455,7 +5456,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v == 0 { code = code.nextField } else { @@ -5471,7 +5472,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagFloat64: @@ -5482,7 +5483,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5497,7 +5498,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5507,7 +5508,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadOmitEmptyFloat64Only, opStructFieldHeadOmitEmptyFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if v != 0 { if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) @@ -5522,7 +5523,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5531,7 +5532,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeComma(b) code = code.next case opStructFieldPtrHeadFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat64Ptr: p := load(ctxptr, code.idx) @@ -5543,11 +5544,11 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5557,7 +5558,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyFloat64Ptr: p := load(ctxptr, code.idx) @@ -5567,10 +5568,10 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5580,7 +5581,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next } case opStructFieldPtrHeadStringTagFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagFloat64Ptr: p := load(ctxptr, code.idx) @@ -5592,12 +5593,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5615,7 +5616,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5624,7 +5625,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5640,14 +5641,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyFloat64PtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5663,7 +5664,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5673,7 +5674,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5693,12 +5694,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5708,14 +5709,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5727,7 +5728,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadOmitEmptyFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64: @@ -5735,12 +5736,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5752,7 +5753,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagFloat64: @@ -5762,7 +5763,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5777,7 +5778,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5790,12 +5791,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5811,7 +5812,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5821,7 +5822,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next } case opStructFieldPtrAnonymousHeadFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat64Ptr: p := load(ctxptr, code.idx) @@ -5830,11 +5831,11 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5843,7 +5844,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64Ptr: p := load(ctxptr, code.idx) @@ -5851,12 +5852,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5865,7 +5866,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next } case opStructFieldPtrAnonymousHeadStringTagFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat64Ptr: p := load(ctxptr, code.idx) @@ -5874,12 +5875,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5894,7 +5895,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5902,7 +5903,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5916,7 +5917,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5924,7 +5925,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5938,7 +5939,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) @@ -5947,7 +5948,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p + code.offset) + v := ptrToFloat64(p + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5964,7 +5965,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadString: ptr := load(ctxptr, code.idx) @@ -5975,14 +5976,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyString: @@ -5993,7 +5994,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { @@ -6006,7 +6007,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagString: @@ -6018,7 +6019,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, s))) b = encodeComma(b) code = code.next @@ -6027,13 +6028,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyStringOnly, opStructFieldHeadOmitEmptyStringOnly: p := load(ctxptr, code.idx) b = append(b, '{') - v := e.ptrToString(p) + v := ptrToString(p) if v != "" { b = append(b, code.escapedKey...) b = encodeEscapedString(b, v) @@ -6044,11 +6045,11 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod p := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) b = encodeComma(b) code = code.next case opStructFieldPtrHeadStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringPtr: p := load(ctxptr, code.idx) @@ -6060,17 +6061,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyStringPtr: p := load(ctxptr, code.idx) @@ -6080,16 +6081,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) b = encodeComma(b) } code = code.next } case opStructFieldPtrHeadStringTagStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagStringPtr: p := load(ctxptr, code.idx) @@ -6101,11 +6102,11 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) } } b = encodeComma(b) @@ -6118,7 +6119,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringPtrOnly: p := load(ctxptr, code.idx) @@ -6127,7 +6128,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } b = encodeComma(b) code = code.next @@ -6139,14 +6140,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyStringPtrOnly: b = append(b, '{') p := load(ctxptr, code.idx) if p != 0 { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) b = encodeComma(b) } code = code.next @@ -6158,7 +6159,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) @@ -6167,7 +6168,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) } b = encodeComma(b) code = code.next @@ -6182,18 +6183,18 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadString: ptr := load(ctxptr, code.idx) @@ -6201,14 +6202,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyString: @@ -6216,7 +6217,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { @@ -6229,7 +6230,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagString: @@ -6238,7 +6239,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(ptr)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(ptr)))) b = encodeComma(b) code = code.next } @@ -6248,7 +6249,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -6257,7 +6258,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { @@ -6273,12 +6274,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(ptr)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(ptr)))) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringPtr: p := load(ctxptr, code.idx) @@ -6287,16 +6288,16 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyStringPtr: p := load(ctxptr, code.idx) @@ -6304,17 +6305,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagStringPtr: p := load(ctxptr, code.idx) @@ -6323,11 +6324,11 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod break } b = append(b, code.escapedKey...) - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) } b = encodeComma(b) code = code.next @@ -6337,7 +6338,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringPtrOnly: p := load(ctxptr, code.idx) @@ -6345,7 +6346,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } b = encodeComma(b) code = code.next @@ -6355,7 +6356,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyStringPtrOnly: p := load(ctxptr, code.idx) @@ -6363,7 +6364,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) b = encodeComma(b) code = code.next } @@ -6373,7 +6374,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) @@ -6381,7 +6382,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) } b = encodeComma(b) code = code.next @@ -6393,7 +6394,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadBool: ptr := load(ctxptr, code.idx) @@ -6408,7 +6409,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -6425,11 +6426,11 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.idx) b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadBool: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadBool: ptr := load(ctxptr, code.idx) @@ -6437,7 +6438,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -6449,7 +6450,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadBytes: ptr := load(ctxptr, code.idx) @@ -6464,12 +6465,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadBytes: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadBytes: ptr := load(ctxptr, code.idx) @@ -6477,7 +6478,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next } @@ -6489,7 +6490,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadArray: ptr := load(ctxptr, code.idx) + code.offset @@ -6510,7 +6511,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod store(ctxptr, code.idx, ptr) } case opStructFieldPtrAnonymousHeadArray: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadArray: ptr := load(ctxptr, code.idx) + code.offset @@ -6529,7 +6530,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadSlice: ptr := load(ctxptr, code.idx) @@ -6551,7 +6552,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod store(ctxptr, code.idx, p) } case opStructFieldPtrAnonymousHeadSlice: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadSlice: ptr := load(ctxptr, code.idx) @@ -6571,7 +6572,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadMarshalJSON: ptr := load(ctxptr, code.idx) @@ -6583,7 +6584,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) ptr += code.offset - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) rv := reflect.ValueOf(v) if rv.Type().Kind() == reflect.Interface && rv.IsNil() { b = encodeNull(b) @@ -6609,7 +6610,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next } case opStructFieldPtrAnonymousHeadMarshalJSON: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadMarshalJSON: ptr := load(ctxptr, code.idx) @@ -6618,7 +6619,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) ptr += code.offset - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) rv := reflect.ValueOf(v) if rv.Type().Kind() == reflect.Interface && rv.IsNil() { b = encodeNull(b) @@ -6651,7 +6652,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadMarshalText: ptr := load(ctxptr, code.idx) @@ -6663,7 +6664,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) ptr += code.offset - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) rv := reflect.ValueOf(v) if rv.Type().Kind() == reflect.Interface && rv.IsNil() { b = encodeNull(b) @@ -6680,7 +6681,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next } case opStructFieldPtrAnonymousHeadMarshalText: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadMarshalText: ptr := load(ctxptr, code.idx) @@ -6689,7 +6690,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) ptr += code.offset - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) rv := reflect.ValueOf(v) if rv.Type().Kind() == reflect.Interface && rv.IsNil() { b = encodeNull(b) @@ -6708,7 +6709,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyBool: @@ -6719,7 +6720,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if !v { code = code.nextField } else { @@ -6732,7 +6733,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyBool: @@ -6740,7 +6741,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if !v { code = code.nextField } else { @@ -6753,7 +6754,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyBytes: @@ -6764,7 +6765,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, '{') - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) == 0 { code = code.nextField } else { @@ -6777,7 +6778,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyBytes: @@ -6785,7 +6786,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod if ptr == 0 { code = code.end.next } else { - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) == 0 { code = code.nextField } else { @@ -6798,7 +6799,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadOmitEmptyMarshalJSON: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyMarshalJSON: @@ -6810,7 +6811,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr if p == nil || (!isPtr && *(*unsafe.Pointer)(p) == nil) { code = code.nextField @@ -6846,7 +6847,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadOmitEmptyMarshalJSON: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyMarshalJSON: @@ -6855,7 +6856,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr if p == nil || (!isPtr && *(*unsafe.Pointer)(p) == nil) { code = code.nextField @@ -6891,7 +6892,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadOmitEmptyMarshalText: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyMarshalText: @@ -6903,7 +6904,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr if p == nil || (!isPtr && *(*unsafe.Pointer)(p) == nil) { code = code.nextField @@ -6925,7 +6926,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadOmitEmptyMarshalText: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadOmitEmptyMarshalText: @@ -6934,7 +6935,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr if p == nil || (!isPtr && *(*unsafe.Pointer)(p) == nil) { code = code.nextField @@ -6956,7 +6957,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTag: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTag: @@ -6975,7 +6976,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTag: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTag: @@ -6990,7 +6991,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagBool: @@ -7003,7 +7004,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -7022,14 +7023,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod b = append(b, '{') b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldPtrAnonymousHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagBool: @@ -7039,7 +7040,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next @@ -7047,7 +7048,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagBytes: @@ -7059,14 +7060,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') b = append(b, code.escapedKey...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagBytes: @@ -7075,14 +7076,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { b = append(b, code.escapedKey...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next } case opStructFieldPtrHeadStringTagMarshalJSON: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagMarshalJSON: @@ -7094,7 +7095,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr v := *(*interface{})(unsafe.Pointer(&interfaceHeader{typ: code.typ, ptr: p})) bb, err := v.(Marshaler).MarshalJSON() @@ -7117,7 +7118,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { var buf bytes.Buffer - if err := compact(&buf, bb, e.enabledHTMLEscape); err != nil { + if err := compact(&buf, bb, true); err != nil { return nil, err } b = append(b, code.escapedKey...) @@ -7129,7 +7130,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagMarshalJSON: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagMarshalJSON: @@ -7138,7 +7139,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) isPtr := code.typ.Kind() == reflect.Ptr v := *(*interface{})(unsafe.Pointer(&interfaceHeader{typ: code.typ, ptr: p})) bb, err := v.(Marshaler).MarshalJSON() @@ -7161,7 +7162,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.nextField } else { var buf bytes.Buffer - if err := compact(&buf, bb, e.enabledHTMLEscape); err != nil { + if err := compact(&buf, bb, true); err != nil { return nil, err } b = append(b, code.escapedKey...) @@ -7173,7 +7174,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrHeadStringTagMarshalText: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagMarshalText: @@ -7185,7 +7186,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod } else { b = append(b, '{') ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) v := *(*interface{})(unsafe.Pointer(&interfaceHeader{typ: code.typ, ptr: p})) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { @@ -7202,7 +7203,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldPtrAnonymousHeadStringTagMarshalText: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldAnonymousHeadStringTagMarshalText: @@ -7211,7 +7212,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.end.next } else { ptr += code.offset - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) v := *(*interface{})(unsafe.Pointer(&interfaceHeader{typ: code.typ, ptr: p})) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { @@ -7248,12 +7249,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldInt: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, int64(v)) @@ -7264,47 +7265,47 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldIntPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } b = encodeComma(b) code = code.next case opStructFieldIntNPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } b = encodeComma(b) code = code.next case opStructFieldInt8: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, int64(v)) @@ -7315,30 +7316,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldInt8Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) } b = encodeComma(b) code = code.next case opStructFieldInt16: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, int64(v)) @@ -7349,30 +7350,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldInt16Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) } b = encodeComma(b) code = code.next case opStructFieldInt32: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, int64(v)) @@ -7383,30 +7384,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldInt32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) } b = encodeComma(b) code = code.next case opStructFieldInt64: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyInt64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, v) @@ -7417,30 +7418,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldInt64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) } b = encodeComma(b) code = code.next case opStructFieldUint: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, uint64(v)) @@ -7451,30 +7452,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUintPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) } b = encodeComma(b) code = code.next case opStructFieldUint8: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, uint64(v)) @@ -7485,30 +7486,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUint8Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) } b = encodeComma(b) code = code.next case opStructFieldUint16: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, uint64(v)) @@ -7519,30 +7520,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUint16Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) } b = encodeComma(b) code = code.next case opStructFieldUint32: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, uint64(v)) @@ -7553,30 +7554,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUint32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) } b = encodeComma(b) code = code.next case opStructFieldUint64: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyUint64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, v) @@ -7587,30 +7588,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint64(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint64(ptr+code.offset))) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldUint64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) } b = encodeComma(b) code = code.next case opStructFieldFloat32: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyFloat32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = encodeFloat32(b, v) @@ -7621,25 +7622,25 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldFloat32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = encodeComma(b) code = code.next case opStructFieldFloat64: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -7648,7 +7649,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next case opStructFieldOmitEmptyFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v != 0 { if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) @@ -7660,7 +7661,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next case opStructFieldStringTagFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -7673,14 +7674,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldFloat64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) b = encodeComma(b) code = code.next break } - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -7690,12 +7691,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldString: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyString: ptr := load(ctxptr, code.headIdx) - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v != "" { b = append(b, code.escapedKey...) b = encodeEscapedString(b, v) @@ -7705,50 +7706,50 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldStringTagString: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, s))) b = encodeComma(b) code = code.next case opStructFieldStringPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) } b = encodeComma(b) code = code.next case opStructFieldOmitEmptyStringPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeComma(b) } code = code.next case opStructFieldStringTagStringPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) } b = encodeComma(b) code = code.next case opStructFieldBool: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyBool: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if v { b = append(b, code.escapedKey...) b = encodeBool(b, v) @@ -7759,30 +7760,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeComma(b) code = code.next case opStructFieldBoolPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeBool(b, e.ptrToBool(p)) + b = encodeBool(b, ptrToBool(p)) } b = encodeComma(b) code = code.next case opStructFieldBytes: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeComma(b) code = code.next case opStructFieldOmitEmptyBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) > 0 { b = append(b, code.escapedKey...) b = encodeByteSlice(b, v) @@ -7791,7 +7792,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next case opStructFieldStringTagBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) b = append(b, code.escapedKey...) b = encodeByteSlice(b, v) b = encodeComma(b) @@ -7800,7 +7801,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -7816,9 +7817,9 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) p := ptr + code.offset if code.typ.Kind() == reflect.Ptr && code.typ.Elem().Implements(marshalJSONType) { - p = e.ptrToPtr(p) + p = ptrToPtr(p) } - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) if v != nil && p != 0 { bb, err := v.(Marshaler).MarshalJSON() if err != nil { @@ -7836,13 +7837,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) } var buf bytes.Buffer - if err := compact(&buf, bb, e.enabledHTMLEscape); err != nil { + if err := compact(&buf, bb, true); err != nil { return nil, err } b = append(b, code.escapedKey...) @@ -7853,7 +7854,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -7864,7 +7865,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldOmitEmptyMarshalText: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) if v != nil { bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { @@ -7878,7 +7879,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldStringTagMarshalText: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -7896,7 +7897,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldOmitEmptyArray: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - array := e.ptrToSlice(p) + array := ptrToSlice(p) if p == 0 || uintptr(array.data) == 0 { code = code.nextField } else { @@ -7913,7 +7914,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructFieldOmitEmptySlice: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) if p == 0 || uintptr(slice.data) == 0 { code = code.nextField } else { @@ -7983,12 +7984,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndInt: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, int64(v)) @@ -8007,27 +8008,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndIntPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyIntPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8042,12 +8043,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagIntPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8055,29 +8056,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndIntNPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } b = appendStructEnd(b) code = code.next case opStructEndInt8: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, int64(v)) @@ -8096,27 +8097,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndInt8Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt8Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8131,12 +8132,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagInt8Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8144,29 +8145,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndInt8NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) } b = appendStructEnd(b) code = code.next case opStructEndInt16: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, int64(v)) @@ -8185,27 +8186,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndInt16Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt16Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8220,12 +8221,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagInt16Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8233,29 +8234,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndInt16NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) } b = appendStructEnd(b) code = code.next case opStructEndInt32: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, int64(v)) @@ -8274,27 +8275,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndInt32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8309,12 +8310,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagInt32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8322,29 +8323,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndInt32NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) } b = appendStructEnd(b) code = code.next case opStructEndInt64: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendInt(b, v) @@ -8363,27 +8364,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndInt64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyInt64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8398,12 +8399,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagInt64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = append(b, '"') } b = appendStructEnd(b) @@ -8411,29 +8412,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndInt64NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) } b = appendStructEnd(b) code = code.next case opStructEndUint: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, uint64(v)) @@ -8452,27 +8453,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUintPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUintPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8487,12 +8488,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagUintPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8500,29 +8501,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndUintNPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) } b = appendStructEnd(b) code = code.next case opStructEndUint8: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, uint64(v)) @@ -8541,27 +8542,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUint8Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint8Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8576,12 +8577,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagUint8Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8589,29 +8590,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndUint8NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) } b = appendStructEnd(b) code = code.next case opStructEndUint16: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, uint64(v)) @@ -8630,27 +8631,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUint16Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint16Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8665,12 +8666,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagUint16Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8678,29 +8679,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndUint16NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) } b = appendStructEnd(b) code = code.next case opStructEndUint32: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, uint64(v)) @@ -8719,27 +8720,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUint32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8754,12 +8755,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagUint32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = append(b, '"') } b = appendStructEnd(b) @@ -8767,29 +8768,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndUint32NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) } b = appendStructEnd(b) code = code.next case opStructEndUint64: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = appendUint(b, v) @@ -8808,27 +8809,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndUint64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyUint64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8843,12 +8844,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagUint64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = append(b, '"') } b = appendStructEnd(b) @@ -8856,29 +8857,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndUint64NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) } b = appendStructEnd(b) code = code.next case opStructEndFloat32: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyFloat32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v != 0 { b = append(b, code.escapedKey...) b = encodeFloat32(b, v) @@ -8897,27 +8898,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndFloat32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyFloat32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -8932,12 +8933,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagFloat32Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = append(b, '"') } b = appendStructEnd(b) @@ -8945,24 +8946,24 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndFloat32NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = appendStructEnd(b) code = code.next case opStructEndFloat64: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -8971,7 +8972,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next case opStructEndOmitEmptyFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v != 0 { if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) @@ -8991,7 +8992,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next case opStructEndStringTagFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9004,14 +9005,14 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndFloat64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) b = appendStructEnd(b) code = code.next break } - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9020,10 +9021,10 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next case opStructEndOmitEmptyFloat64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9042,12 +9043,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagFloat64Ptr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9059,17 +9060,17 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndFloat64NPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -9080,12 +9081,12 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndString: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyString: ptr := load(ctxptr, code.headIdx) - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v != "" { b = append(b, code.escapedKey...) b = encodeEscapedString(b, v) @@ -9103,27 +9104,27 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagString: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, s))) b = appendStructEnd(b) code = code.next case opStructEndStringPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) } b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyStringPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { b = append(b, code.escapedKey...) - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) b = appendStructEnd(b) } else { last := len(b) - 1 @@ -9138,11 +9139,11 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagStringPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToString(p) + v := ptrToString(p) b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, v))) } b = appendStructEnd(b) @@ -9150,29 +9151,29 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringNPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) for i := 0; i < code.ptrNum-1; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) } b = appendStructEnd(b) code = code.next case opStructEndBool: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyBool: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if v { b = append(b, code.escapedKey...) b = encodeBool(b, v) @@ -9191,30 +9192,30 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) b = append(b, '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = appendStructEnd(b) code = code.next case opStructEndBoolPtr: b = append(b, code.escapedKey...) ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeBool(b, e.ptrToBool(p)) + b = encodeBool(b, ptrToBool(p)) } b = appendStructEnd(b) code = code.next case opStructEndBytes: ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = appendStructEnd(b) code = code.next case opStructEndOmitEmptyBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) > 0 { b = append(b, code.escapedKey...) b = encodeByteSlice(b, v) @@ -9231,7 +9232,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod code = code.next case opStructEndStringTagBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) b = append(b, code.escapedKey...) b = encodeByteSlice(b, v) b = appendStructEnd(b) @@ -9240,7 +9241,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9255,8 +9256,8 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndOmitEmptyMarshalJSON: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) - if v != nil && (code.typ.Kind() != reflect.Ptr || e.ptrToPtr(p) != 0) { + v := ptrToInterface(code, p) + if v != nil && (code.typ.Kind() != reflect.Ptr || ptrToPtr(p) != 0) { bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9281,13 +9282,13 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) } var buf bytes.Buffer - if err := compact(&buf, bb, e.enabledHTMLEscape); err != nil { + if err := compact(&buf, bb, true); err != nil { return nil, err } b = append(b, code.escapedKey...) @@ -9298,7 +9299,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod ptr := load(ctxptr, code.headIdx) b = append(b, code.escapedKey...) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -9309,7 +9310,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndOmitEmptyMarshalText: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) if v != nil { bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { @@ -9331,7 +9332,7 @@ func (e *Encoder) runEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcod case opStructEndStringTagMarshalText: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) diff --git a/encode_vm_escaped_indent.go b/encode_vm_escaped_indent.go index 98bff40..1c62cf7 100644 --- a/encode_vm_escaped_indent.go +++ b/encode_vm_escaped_indent.go @@ -12,7 +12,7 @@ import ( "unsafe" ) -func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ([]byte, error) { +func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, opt EncodeOption) ([]byte, error) { ptrOffset := uintptr(0) ctxptr := ctx.ptr() code := codeSet.code @@ -24,113 +24,113 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opPtr: ptr := load(ctxptr, code.idx) code = code.next - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) case opInt: - b = appendInt(b, int64(e.ptrToInt(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opInt8: - b = appendInt(b, int64(e.ptrToInt8(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt8(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opInt16: - b = appendInt(b, int64(e.ptrToInt16(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt16(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opInt32: - b = appendInt(b, int64(e.ptrToInt32(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt32(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opInt64: - b = appendInt(b, e.ptrToInt64(load(ctxptr, code.idx))) + b = appendInt(b, ptrToInt64(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opUint: - b = appendUint(b, uint64(e.ptrToUint(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opUint8: - b = appendUint(b, uint64(e.ptrToUint8(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint8(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opUint16: - b = appendUint(b, uint64(e.ptrToUint16(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint16(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opUint32: - b = appendUint(b, uint64(e.ptrToUint32(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint32(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opUint64: - b = appendUint(b, e.ptrToUint64(load(ctxptr, code.idx))) + b = appendUint(b, ptrToUint64(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opIntString: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opInt8String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt8(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opInt16String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt16(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opInt32String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt32(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opInt64String: b = append(b, '"') - b = appendInt(b, e.ptrToInt64(load(ctxptr, code.idx))) + b = appendInt(b, ptrToInt64(load(ctxptr, code.idx))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUintString: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUint8String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint8(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUint16String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint16(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUint32String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint32(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUint64String: b = append(b, '"') - b = appendUint(b, e.ptrToUint64(load(ctxptr, code.idx))) + b = appendUint(b, ptrToUint64(load(ctxptr, code.idx))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opFloat32: - b = encodeFloat32(b, e.ptrToFloat32(load(ctxptr, code.idx))) + b = encodeFloat32(b, ptrToFloat32(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opFloat64: - v := e.ptrToFloat64(load(ctxptr, code.idx)) + v := ptrToFloat64(load(ctxptr, code.idx)) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -138,20 +138,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.next case opString: - b = encodeEscapedString(b, e.ptrToString(load(ctxptr, code.idx))) + b = encodeEscapedString(b, ptrToString(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opBool: - b = encodeBool(b, e.ptrToBool(load(ctxptr, code.idx))) + b = encodeBool(b, ptrToBool(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opBytes: ptr := load(ctxptr, code.idx) - slice := e.ptrToSlice(ptr) + slice := ptrToSlice(ptr) if ptr == 0 || uintptr(slice.data) == 0 { b = encodeNull(b) } else { - b = encodeByteSlice(b, e.ptrToBytes(ptr)) + b = encodeByteSlice(b, ptrToBytes(ptr)) } b = encodeIndentComma(b) code = code.next @@ -169,7 +169,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } ctx.seenPtr = append(ctx.seenPtr, ptr) - iface := (*interfaceHeader)(e.ptrToUnsafePtr(ptr)) + iface := (*interfaceHeader)(ptrToUnsafePtr(ptr)) if iface == nil || iface.ptr == nil { b = encodeNull(b) b = encodeIndentComma(b) @@ -177,7 +177,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(iface)) - ifaceCodeSet, err := e.compileToGetCodeSet(uintptr(unsafe.Pointer(iface.typ))) + ifaceCodeSet, err := encodeCompileToGetCodeSet(uintptr(unsafe.Pointer(iface.typ))) if err != nil { return nil, err } @@ -199,13 +199,13 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet ctx.ptrs = newPtrs - oldBaseIndent := e.baseIndent - e.baseIndent = code.indent - bb, err := e.runEscapedIndent(ctx, b, ifaceCodeSet) + oldBaseIndent := ctx.baseIndent + ctx.baseIndent = code.indent + bb, err := encodeRunEscapedIndent(ctx, b, ifaceCodeSet, opt) if err != nil { return nil, err } - e.baseIndent = oldBaseIndent + ctx.baseIndent = oldBaseIndent ctx.ptrs = oldPtrs ctxptr = ctx.ptr() @@ -221,7 +221,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next break } - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -241,8 +241,8 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } @@ -252,7 +252,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opMarshalText: ptr := load(ctxptr, code.idx) isPtr := code.typ.Kind() == reflect.Ptr - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) if p == nil { b = encodeNull(b) b = encodeIndentComma(b) @@ -277,22 +277,22 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opSliceHead: p := load(ctxptr, code.idx) if p == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) store(ctxptr, code.elemIdx, 0) store(ctxptr, code.length, uintptr(slice.len)) store(ctxptr, code.idx, uintptr(slice.data)) if slice.len > 0 { b = append(b, '[', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) code = code.next store(ctxptr, code.idx, uintptr(slice.data)) } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '[', ']', '\n') code = code.end.next } @@ -300,22 +300,22 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opRootSliceHead: p := load(ctxptr, code.idx) if p == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) store(ctxptr, code.elemIdx, 0) store(ctxptr, code.length, uintptr(slice.len)) store(ctxptr, code.idx, uintptr(slice.data)) if slice.len > 0 { b = append(b, '[', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) code = code.next store(ctxptr, code.idx, uintptr(slice.data)) } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '[', ']', ',', '\n') code = code.end.next } @@ -325,7 +325,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet length := load(ctxptr, code.length) idx++ if idx < length { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) data := load(ctxptr, code.headIdx) size := code.size @@ -334,7 +334,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } else { b = b[:len(b)-2] b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, ']', ',', '\n') code = code.end.next } @@ -343,33 +343,33 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet length := load(ctxptr, code.length) idx++ if idx < length { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) code = code.next data := load(ctxptr, code.headIdx) store(ctxptr, code.idx, data+idx*code.size) } else { b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, ']') code = code.end.next } case opArrayHead: p := load(ctxptr, code.idx) if p == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { if code.length > 0 { b = append(b, '[', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, 0) code = code.next store(ctxptr, code.idx, p) } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '[', ']', ',', '\n') code = code.end.next } @@ -378,7 +378,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet idx := load(ctxptr, code.elemIdx) idx++ if idx < code.length { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) p := load(ctxptr, code.headIdx) size := code.size @@ -387,19 +387,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } else { b = b[:len(b)-2] b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, ']', ',', '\n') code = code.end.next } case opMapHead: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - uptr := e.ptrToUnsafePtr(ptr) + uptr := ptrToUnsafePtr(ptr) mlen := maplen(uptr) if mlen > 0 { b = append(b, '{', '\n') @@ -409,20 +409,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet store(ctxptr, code.length, uintptr(mlen)) store(ctxptr, code.mapIter, uintptr(iter)) - if !e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) == 0 { mapCtx := newMapContext(mlen) mapCtx.pos = append(mapCtx.pos, len(b)) ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } else { - b = e.encodeIndent(b, code.next.indent) + b = encodeIndent(ctx, b, code.next.indent) } key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) code = code.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next } @@ -430,15 +430,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opMapHeadLoad: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) code = code.end.next } else { // load pointer - ptr = e.ptrToPtr(ptr) - uptr := e.ptrToUnsafePtr(ptr) + ptr = ptrToPtr(ptr) + uptr := ptrToUnsafePtr(ptr) if uintptr(uptr) == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -455,18 +455,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) - if !e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) == 0 { mapCtx := newMapContext(mlen) mapCtx.pos = append(mapCtx.pos, len(b)) ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } else { - b = e.encodeIndent(b, code.next.indent) + b = encodeIndent(ctx, b, code.next.indent) } code = code.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next } @@ -475,29 +475,29 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet idx := load(ctxptr, code.elemIdx) length := load(ctxptr, code.length) idx++ - if e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) != 0 { if idx < length { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) store(ctxptr, code.elemIdx, idx) ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) code = code.next } else { last := len(b) - 1 b[last] = '\n' - b = e.encodeIndent(b, code.indent-1) + b = encodeIndent(ctx, b, code.indent-1) b = append(b, '}', ',', '\n') code = code.end.next } } else { ptr := load(ctxptr, code.end.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) mapCtx.pos = append(mapCtx.pos, len(b)) if idx < length { ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) store(ctxptr, code.elemIdx, idx) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) @@ -507,15 +507,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opMapValue: - if e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) != 0 { b = append(b, ':', ' ') } else { ptr := load(ctxptr, code.end.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) mapCtx.pos = append(mapCtx.pos, len(b)) } ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) value := mapitervalue(iter) store(ctxptr, code.next.idx, uintptr(value)) mapiternext(iter) @@ -524,7 +524,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet // this operation only used by sorted map length := int(load(ctxptr, code.length)) ptr := load(ctxptr, code.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) pos := mapCtx.pos for i := 0; i < length; i++ { startKey := pos[i*2] @@ -543,8 +543,8 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet sort.Sort(mapCtx.slice) buf := mapCtx.buf for _, item := range mapCtx.slice.items { - buf = append(buf, e.prefix...) - buf = append(buf, bytes.Repeat(e.indentStr, e.baseIndent+code.indent+1)...) + buf = append(buf, ctx.prefix...) + buf = append(buf, bytes.Repeat(ctx.indentStr, ctx.baseIndent+code.indent+1)...) buf = append(buf, item.key...) buf[len(buf)-2] = ':' buf[len(buf)-1] = ' ' @@ -552,8 +552,8 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } buf = buf[:len(buf)-2] buf = append(buf, '\n') - buf = append(buf, e.prefix...) - buf = append(buf, bytes.Repeat(e.indentStr, e.baseIndent+code.indent)...) + buf = append(buf, ctx.prefix...) + buf = append(buf, bytes.Repeat(ctx.indentStr, ctx.baseIndent+code.indent)...) buf = append(buf, '}', ',', '\n') b = b[:pos[0]] @@ -568,25 +568,25 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHead: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else if code.next == code.end { // not exists fields - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next store(ctxptr, code.idx, ptr) } else { b = append(b, '{', '\n') if !code.anonymousKey { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') } @@ -597,24 +597,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') p := ptr + code.offset if p == 0 || *(*uintptr)(*(*unsafe.Pointer)(unsafe.Pointer(&p))) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next @@ -625,7 +625,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet ptr := load(ctxptr, code.idx) b = append(b, '{', '\n') if !code.anonymousKey { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') } @@ -636,7 +636,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet ptr := load(ctxptr, code.idx) b = append(b, '{', '\n') if !code.anonymousKey && ptr != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset @@ -646,7 +646,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.nextField } case opStructFieldPtrHeadInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt: ptr := load(ctxptr, code.idx) @@ -656,17 +656,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt: @@ -677,11 +677,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -692,7 +692,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt: @@ -703,10 +703,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -714,18 +714,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadIntOnly, opStructFieldHeadIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyIntOnly, opStructFieldHeadOmitEmptyIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := int64(e.ptrToInt(p)) + v := int64(ptrToInt(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -735,15 +735,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagIntOnly, opStructFieldHeadStringTagIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadIntPtr: p := load(ctxptr, code.idx) @@ -754,20 +754,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyIntPtr: p := load(ctxptr, code.idx) @@ -777,18 +777,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagIntPtr: p := load(ctxptr, code.idx) @@ -799,15 +799,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } } @@ -821,18 +821,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -844,16 +844,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -865,19 +865,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -888,51 +888,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -941,18 +941,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -962,10 +962,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -974,11 +974,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -991,17 +991,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadIntPtr: p := load(ctxptr, code.idx) @@ -1009,19 +1009,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyIntPtr: p := load(ctxptr, code.idx) @@ -1029,19 +1029,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagIntPtr: p := load(ctxptr, code.idx) @@ -1049,15 +1049,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -1068,17 +1068,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadIntPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -1088,17 +1088,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyIntPtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -1108,24 +1108,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt8: ptr := load(ctxptr, code.idx) @@ -1135,17 +1135,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(ptr))) + b = appendInt(b, int64(ptrToInt8(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt8: @@ -1156,11 +1156,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1171,7 +1171,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt8: @@ -1182,10 +1182,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -1193,18 +1193,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadInt8Only, opStructFieldHeadInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt8Only, opStructFieldHeadOmitEmptyInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := int64(e.ptrToInt8(p)) + v := int64(ptrToInt8(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -1214,15 +1214,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt8Only, opStructFieldHeadStringTagInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt8Ptr: p := load(ctxptr, code.idx) @@ -1233,20 +1233,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt8Ptr: p := load(ctxptr, code.idx) @@ -1256,18 +1256,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt8Ptr: p := load(ctxptr, code.idx) @@ -1278,15 +1278,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } } @@ -1300,18 +1300,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -1323,16 +1323,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -1344,19 +1344,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -1367,51 +1367,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1420,18 +1420,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -1441,10 +1441,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -1453,11 +1453,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1470,17 +1470,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt8Ptr: p := load(ctxptr, code.idx) @@ -1488,19 +1488,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8Ptr: p := load(ctxptr, code.idx) @@ -1508,19 +1508,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt8Ptr: p := load(ctxptr, code.idx) @@ -1528,15 +1528,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -1547,17 +1547,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt8PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -1567,17 +1567,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -1587,24 +1587,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt16: ptr := load(ctxptr, code.idx) @@ -1614,17 +1614,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(ptr))) + b = appendInt(b, int64(ptrToInt16(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt16: @@ -1635,11 +1635,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1650,7 +1650,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt16: @@ -1661,10 +1661,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -1672,18 +1672,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadInt16Only, opStructFieldHeadInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt16Only, opStructFieldHeadOmitEmptyInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := int64(e.ptrToInt16(p)) + v := int64(ptrToInt16(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -1693,15 +1693,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt16Only, opStructFieldHeadStringTagInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt16Ptr: p := load(ctxptr, code.idx) @@ -1712,20 +1712,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt16Ptr: p := load(ctxptr, code.idx) @@ -1735,18 +1735,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt16Ptr: p := load(ctxptr, code.idx) @@ -1757,15 +1757,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } } @@ -1779,18 +1779,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -1802,16 +1802,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -1823,19 +1823,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -1846,51 +1846,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1899,18 +1899,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -1920,10 +1920,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -1932,11 +1932,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1949,17 +1949,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt16Ptr: p := load(ctxptr, code.idx) @@ -1967,19 +1967,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16Ptr: p := load(ctxptr, code.idx) @@ -1987,19 +1987,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt16Ptr: p := load(ctxptr, code.idx) @@ -2007,15 +2007,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -2026,17 +2026,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt16PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -2046,17 +2046,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -2066,24 +2066,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt32: ptr := load(ctxptr, code.idx) @@ -2093,17 +2093,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(ptr))) + b = appendInt(b, int64(ptrToInt32(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt32: @@ -2114,11 +2114,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2129,7 +2129,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt32: @@ -2140,10 +2140,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -2151,18 +2151,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadInt32Only, opStructFieldHeadInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt32Only, opStructFieldHeadOmitEmptyInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := int64(e.ptrToInt32(p)) + v := int64(ptrToInt32(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2172,15 +2172,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt32Only, opStructFieldHeadStringTagInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt32Ptr: p := load(ctxptr, code.idx) @@ -2191,20 +2191,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt32Ptr: p := load(ctxptr, code.idx) @@ -2214,18 +2214,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt32Ptr: p := load(ctxptr, code.idx) @@ -2236,15 +2236,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } } @@ -2258,18 +2258,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -2281,16 +2281,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -2302,19 +2302,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -2325,51 +2325,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2378,18 +2378,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -2399,10 +2399,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -2411,11 +2411,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2428,17 +2428,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt32Ptr: p := load(ctxptr, code.idx) @@ -2446,19 +2446,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32Ptr: p := load(ctxptr, code.idx) @@ -2466,19 +2466,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt32Ptr: p := load(ctxptr, code.idx) @@ -2486,15 +2486,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -2505,17 +2505,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -2525,17 +2525,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -2545,24 +2545,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt64: ptr := load(ctxptr, code.idx) @@ -2572,17 +2572,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(ptr)) + b = appendInt(b, ptrToInt64(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt64: @@ -2593,11 +2593,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2608,7 +2608,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt64: @@ -2619,10 +2619,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -2630,18 +2630,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadInt64Only, opStructFieldHeadInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt64Only, opStructFieldHeadOmitEmptyInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToInt64(p) + v := ptrToInt64(p) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2651,15 +2651,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagInt64Only, opStructFieldHeadStringTagInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt64Ptr: p := load(ctxptr, code.idx) @@ -2670,20 +2670,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt64Ptr: p := load(ctxptr, code.idx) @@ -2693,18 +2693,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt64Ptr: p := load(ctxptr, code.idx) @@ -2715,15 +2715,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } } @@ -2737,18 +2737,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -2760,16 +2760,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = encodeIndentComma(b) } code = code.next @@ -2781,19 +2781,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -2804,51 +2804,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2857,18 +2857,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -2878,10 +2878,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -2890,11 +2890,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2907,17 +2907,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt64Ptr: p := load(ctxptr, code.idx) @@ -2925,19 +2925,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64Ptr: p := load(ctxptr, code.idx) @@ -2945,19 +2945,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt64Ptr: p := load(ctxptr, code.idx) @@ -2965,15 +2965,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -2984,17 +2984,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -3004,17 +3004,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -3024,24 +3024,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint: ptr := load(ctxptr, code.idx) @@ -3051,17 +3051,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint: @@ -3072,11 +3072,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3087,7 +3087,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint: @@ -3098,10 +3098,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -3109,18 +3109,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadUintOnly, opStructFieldHeadUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUintOnly, opStructFieldHeadOmitEmptyUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := uint64(e.ptrToUint(p)) + v := uint64(ptrToUint(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -3130,15 +3130,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUintOnly, opStructFieldHeadStringTagUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUintPtr: p := load(ctxptr, code.idx) @@ -3149,20 +3149,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUintPtr: p := load(ctxptr, code.idx) @@ -3172,18 +3172,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUintPtr: p := load(ctxptr, code.idx) @@ -3194,15 +3194,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } } @@ -3216,18 +3216,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -3239,16 +3239,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -3260,19 +3260,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -3283,51 +3283,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3336,18 +3336,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -3357,10 +3357,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -3369,11 +3369,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3386,17 +3386,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUintPtr: p := load(ctxptr, code.idx) @@ -3404,19 +3404,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUintPtr: p := load(ctxptr, code.idx) @@ -3424,19 +3424,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUintPtr: p := load(ctxptr, code.idx) @@ -3444,15 +3444,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -3463,17 +3463,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUintPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -3483,17 +3483,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUintPtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -3503,24 +3503,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint8: ptr := load(ctxptr, code.idx) @@ -3530,17 +3530,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(ptr))) + b = appendUint(b, uint64(ptrToUint8(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint8: @@ -3551,11 +3551,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3566,7 +3566,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint8: @@ -3577,10 +3577,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -3588,18 +3588,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadUint8Only, opStructFieldHeadUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint8Only, opStructFieldHeadOmitEmptyUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := uint64(e.ptrToUint8(p)) + v := uint64(ptrToUint8(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -3609,15 +3609,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint8Only, opStructFieldHeadStringTagUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint8Ptr: p := load(ctxptr, code.idx) @@ -3628,20 +3628,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint8Ptr: p := load(ctxptr, code.idx) @@ -3651,18 +3651,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint8Ptr: p := load(ctxptr, code.idx) @@ -3673,15 +3673,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } } @@ -3695,18 +3695,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -3718,16 +3718,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -3739,19 +3739,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -3762,51 +3762,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3815,18 +3815,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -3836,10 +3836,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -3848,11 +3848,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3865,17 +3865,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint8Ptr: p := load(ctxptr, code.idx) @@ -3883,19 +3883,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8Ptr: p := load(ctxptr, code.idx) @@ -3903,19 +3903,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint8Ptr: p := load(ctxptr, code.idx) @@ -3923,15 +3923,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -3942,17 +3942,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint8PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -3962,17 +3962,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -3982,24 +3982,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint16: ptr := load(ctxptr, code.idx) @@ -4009,17 +4009,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(ptr))) + b = appendUint(b, uint64(ptrToUint16(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint16: @@ -4030,11 +4030,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4045,7 +4045,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint16: @@ -4056,10 +4056,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -4067,18 +4067,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadUint16Only, opStructFieldHeadUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint16Only, opStructFieldHeadOmitEmptyUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := uint64(e.ptrToUint16(p)) + v := uint64(ptrToUint16(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -4088,15 +4088,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint16Only, opStructFieldHeadStringTagUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint16Ptr: p := load(ctxptr, code.idx) @@ -4107,20 +4107,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint16Ptr: p := load(ctxptr, code.idx) @@ -4130,18 +4130,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint16Ptr: p := load(ctxptr, code.idx) @@ -4152,15 +4152,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } } @@ -4174,18 +4174,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -4197,16 +4197,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -4218,19 +4218,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -4241,51 +4241,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4294,18 +4294,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -4315,10 +4315,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -4327,11 +4327,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4344,17 +4344,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint16Ptr: p := load(ctxptr, code.idx) @@ -4362,19 +4362,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16Ptr: p := load(ctxptr, code.idx) @@ -4382,19 +4382,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint16Ptr: p := load(ctxptr, code.idx) @@ -4402,15 +4402,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -4421,17 +4421,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint16PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -4441,17 +4441,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -4461,24 +4461,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint32: ptr := load(ctxptr, code.idx) @@ -4488,17 +4488,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(ptr))) + b = appendUint(b, uint64(ptrToUint32(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint32: @@ -4509,11 +4509,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4524,7 +4524,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint32: @@ -4535,10 +4535,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -4546,18 +4546,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadUint32Only, opStructFieldHeadUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint32Only, opStructFieldHeadOmitEmptyUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := uint64(e.ptrToUint32(p)) + v := uint64(ptrToUint32(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -4567,15 +4567,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint32Only, opStructFieldHeadStringTagUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint32Ptr: p := load(ctxptr, code.idx) @@ -4586,20 +4586,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint32Ptr: p := load(ctxptr, code.idx) @@ -4609,18 +4609,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint32Ptr: p := load(ctxptr, code.idx) @@ -4631,15 +4631,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } } @@ -4653,18 +4653,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -4676,16 +4676,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -4697,19 +4697,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -4720,51 +4720,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4773,18 +4773,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -4794,10 +4794,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -4806,11 +4806,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4823,17 +4823,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint32Ptr: p := load(ctxptr, code.idx) @@ -4841,19 +4841,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32Ptr: p := load(ctxptr, code.idx) @@ -4861,19 +4861,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint32Ptr: p := load(ctxptr, code.idx) @@ -4881,15 +4881,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -4900,17 +4900,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -4920,17 +4920,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -4940,24 +4940,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint64: ptr := load(ctxptr, code.idx) @@ -4967,17 +4967,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(ptr)) + b = appendUint(b, ptrToUint64(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint64: @@ -4988,11 +4988,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -5003,7 +5003,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint64: @@ -5014,10 +5014,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -5025,18 +5025,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadUint64Only, opStructFieldHeadUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint64Only, opStructFieldHeadOmitEmptyUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToUint64(p) + v := ptrToUint64(p) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -5046,15 +5046,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagUint64Only, opStructFieldHeadStringTagUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint64Ptr: p := load(ctxptr, code.idx) @@ -5065,20 +5065,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint64Ptr: p := load(ctxptr, code.idx) @@ -5088,18 +5088,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint64Ptr: p := load(ctxptr, code.idx) @@ -5110,15 +5110,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } } @@ -5132,18 +5132,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -5155,16 +5155,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = encodeIndentComma(b) } code = code.next @@ -5176,19 +5176,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -5199,51 +5199,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -5252,18 +5252,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -5273,10 +5273,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -5285,11 +5285,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -5302,17 +5302,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint64Ptr: p := load(ctxptr, code.idx) @@ -5320,19 +5320,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64Ptr: p := load(ctxptr, code.idx) @@ -5340,19 +5340,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint64Ptr: p := load(ctxptr, code.idx) @@ -5360,15 +5360,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -5379,17 +5379,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -5399,17 +5399,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -5419,24 +5419,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat32: ptr := load(ctxptr, code.idx) @@ -5446,17 +5446,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(ptr)) + b = encodeFloat32(b, ptrToFloat32(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyFloat32: @@ -5467,11 +5467,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5482,7 +5482,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagFloat32: @@ -5493,10 +5493,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -5504,18 +5504,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadFloat32Only, opStructFieldHeadFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat32Only, opStructFieldHeadOmitEmptyFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToFloat32(p) + v := ptrToFloat32(p) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5525,15 +5525,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagFloat32Only, opStructFieldHeadStringTagFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat32Ptr: p := load(ctxptr, code.idx) @@ -5544,20 +5544,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyFloat32Ptr: p := load(ctxptr, code.idx) @@ -5567,18 +5567,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagFloat32Ptr: p := load(ctxptr, code.idx) @@ -5589,15 +5589,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } } @@ -5611,18 +5611,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = encodeIndentComma(b) code = code.next @@ -5634,16 +5634,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = encodeIndentComma(b) } code = code.next @@ -5655,19 +5655,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -5678,51 +5678,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(ptr)) + b = encodeFloat32(b, ptrToFloat32(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5731,18 +5731,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -5752,10 +5752,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(ptr)) + b = encodeFloat32(b, ptrToFloat32(ptr)) b = encodeIndentComma(b) code = code.next } @@ -5764,11 +5764,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5781,17 +5781,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat32Ptr: p := load(ctxptr, code.idx) @@ -5799,19 +5799,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32Ptr: p := load(ctxptr, code.idx) @@ -5819,19 +5819,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat32Ptr: p := load(ctxptr, code.idx) @@ -5839,15 +5839,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -5858,17 +5858,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadFloat32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = encodeIndentComma(b) code = code.next @@ -5878,17 +5878,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -5898,24 +5898,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat64: ptr := load(ctxptr, code.idx) @@ -5924,12 +5924,12 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.end.next } else { - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -5939,7 +5939,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadOmitEmptyFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyFloat64: @@ -5950,14 +5950,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -5968,7 +5968,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagFloat64: @@ -5979,10 +5979,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5994,10 +5994,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadFloat64Only, opStructFieldHeadFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6007,12 +6007,12 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadOmitEmptyFloat64Only, opStructFieldHeadOmitEmptyFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -6022,10 +6022,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagFloat64Only, opStructFieldHeadStringTagFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6034,7 +6034,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat64Ptr: p := load(ctxptr, code.idx) @@ -6045,14 +6045,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6062,7 +6062,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyFloat64Ptr: p := load(ctxptr, code.idx) @@ -6072,12 +6072,12 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6087,7 +6087,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next } case opStructFieldPtrHeadStringTagFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagFloat64Ptr: p := load(ctxptr, code.idx) @@ -6098,15 +6098,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6124,18 +6124,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6151,16 +6151,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6176,19 +6176,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6203,19 +6203,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6225,17 +6225,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6244,21 +6244,21 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -6267,18 +6267,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6292,10 +6292,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6308,14 +6308,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6329,11 +6329,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6343,7 +6343,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next } case opStructFieldPtrAnonymousHeadFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat64Ptr: p := load(ctxptr, code.idx) @@ -6351,14 +6351,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6367,7 +6367,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64Ptr: p := load(ctxptr, code.idx) @@ -6375,14 +6375,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6391,7 +6391,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next } case opStructFieldPtrAnonymousHeadStringTagFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat64Ptr: p := load(ctxptr, code.idx) @@ -6399,15 +6399,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6422,17 +6422,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadFloat64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6446,17 +6446,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6470,18 +6470,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6491,7 +6491,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadString: ptr := load(ctxptr, code.idx) @@ -6501,17 +6501,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(ptr)) + b = encodeEscapedString(b, ptrToString(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyString: @@ -6522,11 +6522,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -6537,7 +6537,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagString: @@ -6548,10 +6548,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, v))) b = encodeIndentComma(b) code = code.next @@ -6559,18 +6559,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringOnly, opStructFieldHeadStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyStringOnly, opStructFieldHeadOmitEmptyStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToString(p) + v := ptrToString(p) if v != "" { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -6580,14 +6580,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagStringOnly, opStructFieldHeadStringTagStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringPtr: p := load(ctxptr, code.idx) @@ -6598,20 +6598,20 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyStringPtr: p := load(ctxptr, code.idx) @@ -6621,18 +6621,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagStringPtr: p := load(ctxptr, code.idx) @@ -6643,14 +6643,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) } } b = encodeIndentComma(b) @@ -6663,18 +6663,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -6686,16 +6686,16 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) b = encodeIndentComma(b) } code = code.next @@ -6707,18 +6707,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p+code.offset)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p+code.offset)))) } b = encodeIndentComma(b) code = code.next @@ -6728,51 +6728,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadString: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyString: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -6781,17 +6781,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } } case opStructFieldPtrAnonymousHeadStringTagString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagString: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(ptr+code.offset)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(ptr+code.offset)))) b = encodeIndentComma(b) code = code.next } @@ -6800,10 +6800,10 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -6812,11 +6812,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -6829,15 +6829,15 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(ptr+code.offset)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(ptr+code.offset)))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringPtr: p := load(ctxptr, code.idx) @@ -6845,19 +6845,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyStringPtr: p := load(ctxptr, code.idx) @@ -6865,19 +6865,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagStringPtr: p := load(ctxptr, code.idx) @@ -6885,14 +6885,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p+code.offset)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p+code.offset)))) } b = encodeIndentComma(b) code = code.next @@ -6902,17 +6902,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -6922,17 +6922,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyStringPtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeEscapedString(b, ptrToString(p+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -6942,81 +6942,81 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p+code.offset)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p+code.offset)))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadBool: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeBool(b, e.ptrToBool(ptr)) + b = encodeBool(b, ptrToBool(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadBytes: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeByteSlice(b, e.ptrToBytes(ptr)) + b = encodeByteSlice(b, ptrToBytes(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if !v { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeBool(b, v) @@ -7027,24 +7027,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -7055,7 +7055,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTag: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTag: @@ -7067,7 +7067,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet } else { b = append(b, '{', '\n') p := ptr + code.offset - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next @@ -7076,22 +7076,22 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -7099,27 +7099,27 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldPtrHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } case opStructField: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7132,7 +7132,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if p == 0 || **(**uintptr)(unsafe.Pointer(&p)) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next @@ -7141,24 +7141,24 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldStringTag: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next store(ctxptr, code.idx, p) case opStructFieldInt: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7167,26 +7167,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagInt: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldInt8: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7195,26 +7195,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagInt8: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldInt16: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7223,26 +7223,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagInt16: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldInt32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7251,26 +7251,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagInt32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldInt64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -7279,26 +7279,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagInt64: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7307,26 +7307,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagUint: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint8: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7335,26 +7335,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagUint8: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint16: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7363,26 +7363,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagUint16: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7391,26 +7391,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagUint32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -7419,26 +7419,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagUint64: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldFloat32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyFloat32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -7447,19 +7447,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagFloat32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldFloat64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -7468,12 +7468,12 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldOmitEmptyFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v != 0 { if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -7482,11 +7482,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeFloat64(b, v) @@ -7494,18 +7494,18 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.next case opStructFieldString: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyString: ptr := load(ctxptr, code.headIdx) - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v != "" { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -7514,63 +7514,63 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagString: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, s))) b = encodeIndentComma(b) code = code.next case opStructFieldStringPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) } b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyStringPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeIndentComma(b) } code = code.next case opStructFieldStringTagStringPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) } b = encodeIndentComma(b) code = code.next case opStructFieldBool: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyBool: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if v { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeBool(b, v) @@ -7579,26 +7579,26 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagBool: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldBytes: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) > 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -7607,19 +7607,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagBytes: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldMarshalJSON: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -7632,8 +7632,8 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } @@ -7642,11 +7642,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -7659,8 +7659,8 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } @@ -7670,11 +7670,11 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructFieldStringTagMarshalText: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -7683,12 +7683,12 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeIndentComma(b) code = code.next case opStructFieldArray: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - array := e.ptrToSlice(p) + array := ptrToSlice(p) if p == 0 || uintptr(array.data) == 0 { b = encodeNull(b) b = encodeIndentComma(b) @@ -7699,22 +7699,22 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldOmitEmptyArray: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - array := e.ptrToSlice(p) + array := ptrToSlice(p) if p == 0 || uintptr(array.data) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next } case opStructFieldSlice: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) if p == 0 || uintptr(slice.data) == 0 { b = encodeNull(b) b = encodeIndentComma(b) @@ -7725,17 +7725,17 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldOmitEmptySlice: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) if p == 0 || uintptr(slice.data) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next } case opStructFieldMap: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7744,8 +7744,8 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) code = code.nextField } else { - p = e.ptrToPtr(p) - mlen := maplen(e.ptrToUnsafePtr(p)) + p = ptrToPtr(p) + mlen := maplen(ptrToUnsafePtr(p)) if mlen == 0 { b = append(b, '{', '}', ',', '\n') mapCode := code.next @@ -7764,14 +7764,14 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if mlen == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next } } case opStructFieldMapLoad: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7780,8 +7780,8 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = encodeNull(b) code = code.nextField } else { - p = e.ptrToPtr(p) - mlen := maplen(e.ptrToUnsafePtr(p)) + p = ptrToPtr(p) + mlen := maplen(ptrToUnsafePtr(p)) if mlen == 0 { b = append(b, '{', '}', ',', '\n') code = code.nextField @@ -7799,7 +7799,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if mlen == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next @@ -7808,7 +7808,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet case opStructFieldStruct: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -7831,7 +7831,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') headCode := code.next @@ -7859,27 +7859,27 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') b = encodeIndentComma(b) code = code.next case opStructEndInt: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -7890,7 +7890,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -7898,35 +7898,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagInt: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndIntPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyIntPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -7937,44 +7937,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagIntPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt8: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -7985,7 +7985,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -7993,35 +7993,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagInt8: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt8Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt8Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt8(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8032,44 +8032,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt8Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt16: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8080,7 +8080,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8088,35 +8088,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagInt16: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt16Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt16Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt16(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8127,44 +8127,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt16Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8175,7 +8175,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8183,35 +8183,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagInt32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt32(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8222,44 +8222,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, ptrToInt64(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8270,7 +8270,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8278,35 +8278,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagInt64: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, ptrToInt64(p)) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8317,44 +8317,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8365,7 +8365,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8373,35 +8373,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagUint: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUintPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUintPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8412,44 +8412,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUintPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint8: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8460,7 +8460,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8468,35 +8468,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagUint8: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint8Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint8Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint8(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8507,44 +8507,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint8Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint16: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8555,7 +8555,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8563,35 +8563,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagUint16: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint16Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint16Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint16(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8602,44 +8602,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint16Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8650,7 +8650,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8658,35 +8658,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagUint32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint32(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8697,44 +8697,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, ptrToUint64(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8745,7 +8745,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8753,35 +8753,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagUint64: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, ptrToUint64(p)) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8792,44 +8792,44 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyFloat32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8840,7 +8840,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8848,35 +8848,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagFloat32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyFloat32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeFloat32(b, ptrToFloat32(p)) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8887,51 +8887,51 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagFloat32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8942,7 +8942,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8950,47 +8950,47 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeFloat64(b, v) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyFloat64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9001,48 +9001,48 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagFloat64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndString: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeEscapedString(b, e.ptrToString(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeEscapedString(b, ptrToString(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyString: ptr := load(ctxptr, code.headIdx) - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v != "" { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9053,7 +9053,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9061,35 +9061,35 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagString: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, s))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndStringPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, e.ptrToString(p)) + b = encodeEscapedString(b, ptrToString(p)) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyStringPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeEscapedString(b, e.ptrToString(p)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeEscapedString(b, ptrToString(p)) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9100,42 +9100,42 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagStringPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndBool: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeBool(b, ptrToBool(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyBool: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if v { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeBool(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9146,7 +9146,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9154,30 +9154,30 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagBool: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndBytes: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) > 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9188,7 +9188,7 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9196,19 +9196,19 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet code = code.next case opStructEndStringTagBytes: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndMarshalJSON: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9221,21 +9221,21 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } b = append(b, indentBuf.Bytes()...) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9248,27 +9248,27 @@ func (e *Encoder) runEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } b = encodeEscapedString(b, indentBuf.String()) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndStringTagMarshalText: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) } b = encodeEscapedString(b, *(*string)(unsafe.Pointer(&bytes))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opEnd: goto END diff --git a/encode_vm_indent.go b/encode_vm_indent.go index ec31248..afcb21f 100644 --- a/encode_vm_indent.go +++ b/encode_vm_indent.go @@ -12,7 +12,7 @@ import ( "unsafe" ) -func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet) ([]byte, error) { +func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, opt EncodeOption) ([]byte, error) { ptrOffset := uintptr(0) ctxptr := ctx.ptr() code := codeSet.code @@ -24,113 +24,113 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opPtr: ptr := load(ctxptr, code.idx) code = code.next - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) case opInt: - b = appendInt(b, int64(e.ptrToInt(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opInt8: - b = appendInt(b, int64(e.ptrToInt8(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt8(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opInt16: - b = appendInt(b, int64(e.ptrToInt16(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt16(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opInt32: - b = appendInt(b, int64(e.ptrToInt32(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt32(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opInt64: - b = appendInt(b, e.ptrToInt64(load(ctxptr, code.idx))) + b = appendInt(b, ptrToInt64(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opUint: - b = appendUint(b, uint64(e.ptrToUint(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opUint8: - b = appendUint(b, uint64(e.ptrToUint8(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint8(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opUint16: - b = appendUint(b, uint64(e.ptrToUint16(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint16(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opUint32: - b = appendUint(b, uint64(e.ptrToUint32(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint32(load(ctxptr, code.idx)))) b = encodeIndentComma(b) code = code.next case opUint64: - b = appendUint(b, e.ptrToUint64(load(ctxptr, code.idx))) + b = appendUint(b, ptrToUint64(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opIntString: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opInt8String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt8(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opInt16String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt16(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opInt32String: b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(load(ctxptr, code.idx)))) + b = appendInt(b, int64(ptrToInt32(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opInt64String: b = append(b, '"') - b = appendInt(b, e.ptrToInt64(load(ctxptr, code.idx))) + b = appendInt(b, ptrToInt64(load(ctxptr, code.idx))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUintString: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUint8String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint8(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUint16String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint16(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUint32String: b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(load(ctxptr, code.idx)))) + b = appendUint(b, uint64(ptrToUint32(load(ctxptr, code.idx)))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opUint64String: b = append(b, '"') - b = appendUint(b, e.ptrToUint64(load(ctxptr, code.idx))) + b = appendUint(b, ptrToUint64(load(ctxptr, code.idx))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opFloat32: - b = encodeFloat32(b, e.ptrToFloat32(load(ctxptr, code.idx))) + b = encodeFloat32(b, ptrToFloat32(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opFloat64: - v := e.ptrToFloat64(load(ctxptr, code.idx)) + v := ptrToFloat64(load(ctxptr, code.idx)) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -138,20 +138,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opString: - b = encodeNoEscapedString(b, e.ptrToString(load(ctxptr, code.idx))) + b = encodeNoEscapedString(b, ptrToString(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opBool: - b = encodeBool(b, e.ptrToBool(load(ctxptr, code.idx))) + b = encodeBool(b, ptrToBool(load(ctxptr, code.idx))) b = encodeIndentComma(b) code = code.next case opBytes: ptr := load(ctxptr, code.idx) - slice := e.ptrToSlice(ptr) + slice := ptrToSlice(ptr) if ptr == 0 || uintptr(slice.data) == 0 { b = encodeNull(b) } else { - b = encodeByteSlice(b, e.ptrToBytes(ptr)) + b = encodeByteSlice(b, ptrToBytes(ptr)) } b = encodeIndentComma(b) code = code.next @@ -169,7 +169,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } ctx.seenPtr = append(ctx.seenPtr, ptr) - iface := (*interfaceHeader)(e.ptrToUnsafePtr(ptr)) + iface := (*interfaceHeader)(ptrToUnsafePtr(ptr)) if iface == nil || iface.ptr == nil { b = encodeNull(b) b = encodeIndentComma(b) @@ -177,7 +177,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(iface)) - ifaceCodeSet, err := e.compileToGetCodeSet(uintptr(unsafe.Pointer(iface.typ))) + ifaceCodeSet, err := encodeCompileToGetCodeSet(uintptr(unsafe.Pointer(iface.typ))) if err != nil { return nil, err } @@ -199,13 +199,13 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ctx.ptrs = newPtrs - oldBaseIndent := e.baseIndent - e.baseIndent = code.indent - bb, err := e.runIndent(ctx, b, ifaceCodeSet) + oldBaseIndent := ctx.baseIndent + ctx.baseIndent = code.indent + bb, err := encodeRunIndent(ctx, b, ifaceCodeSet, opt) if err != nil { return nil, err } - e.baseIndent = oldBaseIndent + ctx.baseIndent = oldBaseIndent ctx.ptrs = oldPtrs ctxptr = ctx.ptr() @@ -221,7 +221,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next break } - v := e.ptrToInterface(code, ptr) + v := ptrToInterface(code, ptr) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -241,8 +241,8 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } @@ -252,7 +252,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opMarshalText: ptr := load(ctxptr, code.idx) isPtr := code.typ.Kind() == reflect.Ptr - p := e.ptrToUnsafePtr(ptr) + p := ptrToUnsafePtr(ptr) if p == nil { b = encodeNull(b) b = encodeIndentComma(b) @@ -277,22 +277,22 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opSliceHead: p := load(ctxptr, code.idx) if p == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) store(ctxptr, code.elemIdx, 0) store(ctxptr, code.length, uintptr(slice.len)) store(ctxptr, code.idx, uintptr(slice.data)) if slice.len > 0 { b = append(b, '[', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) code = code.next store(ctxptr, code.idx, uintptr(slice.data)) } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '[', ']', '\n') code = code.end.next } @@ -300,22 +300,22 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opRootSliceHead: p := load(ctxptr, code.idx) if p == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) store(ctxptr, code.elemIdx, 0) store(ctxptr, code.length, uintptr(slice.len)) store(ctxptr, code.idx, uintptr(slice.data)) if slice.len > 0 { b = append(b, '[', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) code = code.next store(ctxptr, code.idx, uintptr(slice.data)) } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '[', ']', ',', '\n') code = code.end.next } @@ -325,7 +325,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode length := load(ctxptr, code.length) idx++ if idx < length { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) data := load(ctxptr, code.headIdx) size := code.size @@ -334,7 +334,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } else { b = b[:len(b)-2] b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, ']', ',', '\n') code = code.end.next } @@ -343,33 +343,33 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode length := load(ctxptr, code.length) idx++ if idx < length { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) code = code.next data := load(ctxptr, code.headIdx) store(ctxptr, code.idx, data+idx*code.size) } else { b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, ']') code = code.end.next } case opArrayHead: p := load(ctxptr, code.idx) if p == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { if code.length > 0 { b = append(b, '[', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, 0) code = code.next store(ctxptr, code.idx, p) } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '[', ']', ',', '\n') code = code.end.next } @@ -378,7 +378,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode idx := load(ctxptr, code.elemIdx) idx++ if idx < code.length { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) p := load(ctxptr, code.headIdx) size := code.size @@ -387,19 +387,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } else { b = b[:len(b)-2] b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, ']', ',', '\n') code = code.end.next } case opMapHead: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - uptr := e.ptrToUnsafePtr(ptr) + uptr := ptrToUnsafePtr(ptr) mlen := maplen(uptr) if mlen > 0 { b = append(b, '{', '\n') @@ -409,20 +409,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode store(ctxptr, code.length, uintptr(mlen)) store(ctxptr, code.mapIter, uintptr(iter)) - if !e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) == 0 { mapCtx := newMapContext(mlen) mapCtx.pos = append(mapCtx.pos, len(b)) ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } else { - b = e.encodeIndent(b, code.next.indent) + b = encodeIndent(ctx, b, code.next.indent) } key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) code = code.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next } @@ -430,15 +430,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opMapHeadLoad: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) code = code.end.next } else { // load pointer - ptr = e.ptrToPtr(ptr) - uptr := e.ptrToUnsafePtr(ptr) + ptr = ptrToPtr(ptr) + uptr := ptrToUnsafePtr(ptr) if uintptr(uptr) == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -455,18 +455,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) - if !e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) == 0 { mapCtx := newMapContext(mlen) mapCtx.pos = append(mapCtx.pos, len(b)) ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } else { - b = e.encodeIndent(b, code.next.indent) + b = encodeIndent(ctx, b, code.next.indent) } code = code.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next } @@ -475,29 +475,29 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode idx := load(ctxptr, code.elemIdx) length := load(ctxptr, code.length) idx++ - if e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) != 0 { if idx < length { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) store(ctxptr, code.elemIdx, idx) ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) code = code.next } else { last := len(b) - 1 b[last] = '\n' - b = e.encodeIndent(b, code.indent-1) + b = encodeIndent(ctx, b, code.indent-1) b = append(b, '}', ',', '\n') code = code.end.next } } else { ptr := load(ctxptr, code.end.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) mapCtx.pos = append(mapCtx.pos, len(b)) if idx < length { ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) store(ctxptr, code.elemIdx, idx) key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) @@ -507,15 +507,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opMapValue: - if e.unorderedMap { + if (opt & EncodeOptionUnorderedMap) != 0 { b = append(b, ':', ' ') } else { ptr := load(ctxptr, code.end.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) mapCtx.pos = append(mapCtx.pos, len(b)) } ptr := load(ctxptr, code.mapIter) - iter := e.ptrToUnsafePtr(ptr) + iter := ptrToUnsafePtr(ptr) value := mapitervalue(iter) store(ctxptr, code.next.idx, uintptr(value)) mapiternext(iter) @@ -524,7 +524,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode // this operation only used by sorted map length := int(load(ctxptr, code.length)) ptr := load(ctxptr, code.mapPos) - mapCtx := (*encodeMapContext)(e.ptrToUnsafePtr(ptr)) + mapCtx := (*encodeMapContext)(ptrToUnsafePtr(ptr)) pos := mapCtx.pos for i := 0; i < length; i++ { startKey := pos[i*2] @@ -543,8 +543,8 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode sort.Sort(mapCtx.slice) buf := mapCtx.buf for _, item := range mapCtx.slice.items { - buf = append(buf, e.prefix...) - buf = append(buf, bytes.Repeat(e.indentStr, e.baseIndent+code.indent+1)...) + buf = append(buf, ctx.prefix...) + buf = append(buf, bytes.Repeat(ctx.indentStr, ctx.baseIndent+code.indent+1)...) buf = append(buf, item.key...) buf[len(buf)-2] = ':' buf[len(buf)-1] = ' ' @@ -552,8 +552,8 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } buf = buf[:len(buf)-2] buf = append(buf, '\n') - buf = append(buf, e.prefix...) - buf = append(buf, bytes.Repeat(e.indentStr, e.baseIndent+code.indent)...) + buf = append(buf, ctx.prefix...) + buf = append(buf, bytes.Repeat(ctx.indentStr, ctx.baseIndent+code.indent)...) buf = append(buf, '}', ',', '\n') b = b[:pos[0]] @@ -568,25 +568,25 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHead: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else if code.next == code.end { // not exists fields - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next store(ctxptr, code.idx, ptr) } else { b = append(b, '{', '\n') if !code.anonymousKey { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') } @@ -597,24 +597,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') p := ptr + code.offset if p == 0 || *(*uintptr)(*(*unsafe.Pointer)(unsafe.Pointer(&p))) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') code = code.next @@ -625,7 +625,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.idx) b = append(b, '{', '\n') if !code.anonymousKey { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') } @@ -636,7 +636,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.idx) b = append(b, '{', '\n') if !code.anonymousKey && ptr != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset @@ -646,7 +646,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.nextField } case opStructFieldPtrHeadInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt: ptr := load(ctxptr, code.idx) @@ -656,17 +656,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt: @@ -677,11 +677,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -692,7 +692,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt: @@ -703,10 +703,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -714,18 +714,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadIntOnly, opStructFieldHeadIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyIntOnly, opStructFieldHeadOmitEmptyIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := int64(e.ptrToInt(p)) + v := int64(ptrToInt(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -735,15 +735,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagIntOnly, opStructFieldHeadStringTagIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadIntPtr: p := load(ctxptr, code.idx) @@ -754,20 +754,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyIntPtr: p := load(ctxptr, code.idx) @@ -777,18 +777,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagIntPtr: p := load(ctxptr, code.idx) @@ -799,15 +799,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } } @@ -821,18 +821,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -844,16 +844,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -865,19 +865,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -888,51 +888,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -941,18 +941,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagInt: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -962,10 +962,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -974,11 +974,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -991,17 +991,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadIntPtr: p := load(ctxptr, code.idx) @@ -1009,19 +1009,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyIntPtr: p := load(ctxptr, code.idx) @@ -1029,19 +1029,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagIntPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagIntPtr: p := load(ctxptr, code.idx) @@ -1049,15 +1049,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -1068,17 +1068,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadIntPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -1088,17 +1088,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyIntPtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -1108,24 +1108,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p+code.offset))) + b = appendInt(b, int64(ptrToInt(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt8: ptr := load(ctxptr, code.idx) @@ -1135,17 +1135,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(ptr))) + b = appendInt(b, int64(ptrToInt8(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt8: @@ -1156,11 +1156,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1171,7 +1171,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt8: @@ -1182,10 +1182,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -1193,18 +1193,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadInt8Only, opStructFieldHeadInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt8Only, opStructFieldHeadOmitEmptyInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := int64(e.ptrToInt8(p)) + v := int64(ptrToInt8(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -1214,15 +1214,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt8Only, opStructFieldHeadStringTagInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt8Ptr: p := load(ctxptr, code.idx) @@ -1233,20 +1233,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt8Ptr: p := load(ctxptr, code.idx) @@ -1256,18 +1256,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt8Ptr: p := load(ctxptr, code.idx) @@ -1278,15 +1278,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } } @@ -1300,18 +1300,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -1323,16 +1323,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -1344,19 +1344,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -1367,51 +1367,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1420,18 +1420,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagInt8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -1441,10 +1441,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -1453,11 +1453,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1470,17 +1470,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt8Ptr: p := load(ctxptr, code.idx) @@ -1488,19 +1488,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8Ptr: p := load(ctxptr, code.idx) @@ -1508,19 +1508,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt8Ptr: p := load(ctxptr, code.idx) @@ -1528,15 +1528,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -1547,17 +1547,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt8PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -1567,17 +1567,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt8PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -1587,24 +1587,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p+code.offset))) + b = appendInt(b, int64(ptrToInt8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt16: ptr := load(ctxptr, code.idx) @@ -1614,17 +1614,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(ptr))) + b = appendInt(b, int64(ptrToInt16(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt16: @@ -1635,11 +1635,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1650,7 +1650,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt16: @@ -1661,10 +1661,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -1672,18 +1672,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadInt16Only, opStructFieldHeadInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt16Only, opStructFieldHeadOmitEmptyInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := int64(e.ptrToInt16(p)) + v := int64(ptrToInt16(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -1693,15 +1693,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt16Only, opStructFieldHeadStringTagInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt16Ptr: p := load(ctxptr, code.idx) @@ -1712,20 +1712,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt16Ptr: p := load(ctxptr, code.idx) @@ -1735,18 +1735,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt16Ptr: p := load(ctxptr, code.idx) @@ -1757,15 +1757,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } } @@ -1779,18 +1779,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -1802,16 +1802,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -1823,19 +1823,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -1846,51 +1846,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1899,18 +1899,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagInt16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -1920,10 +1920,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -1932,11 +1932,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1949,17 +1949,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt16Ptr: p := load(ctxptr, code.idx) @@ -1967,19 +1967,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16Ptr: p := load(ctxptr, code.idx) @@ -1987,19 +1987,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt16Ptr: p := load(ctxptr, code.idx) @@ -2007,15 +2007,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -2026,17 +2026,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt16PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -2046,17 +2046,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt16PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -2066,24 +2066,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p+code.offset))) + b = appendInt(b, int64(ptrToInt16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt32: ptr := load(ctxptr, code.idx) @@ -2093,17 +2093,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(ptr))) + b = appendInt(b, int64(ptrToInt32(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt32: @@ -2114,11 +2114,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2129,7 +2129,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt32: @@ -2140,10 +2140,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -2151,18 +2151,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadInt32Only, opStructFieldHeadInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt32Only, opStructFieldHeadOmitEmptyInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := int64(e.ptrToInt32(p)) + v := int64(ptrToInt32(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2172,15 +2172,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt32Only, opStructFieldHeadStringTagInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt32Ptr: p := load(ctxptr, code.idx) @@ -2191,20 +2191,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt32Ptr: p := load(ctxptr, code.idx) @@ -2214,18 +2214,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt32Ptr: p := load(ctxptr, code.idx) @@ -2236,15 +2236,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } } @@ -2258,18 +2258,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -2281,16 +2281,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -2302,19 +2302,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -2325,51 +2325,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2378,18 +2378,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagInt32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -2399,10 +2399,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -2411,11 +2411,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2428,17 +2428,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt32Ptr: p := load(ctxptr, code.idx) @@ -2446,19 +2446,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32Ptr: p := load(ctxptr, code.idx) @@ -2466,19 +2466,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt32Ptr: p := load(ctxptr, code.idx) @@ -2486,15 +2486,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -2505,17 +2505,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -2525,17 +2525,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt32PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -2545,24 +2545,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p+code.offset))) + b = appendInt(b, int64(ptrToInt32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt64: ptr := load(ctxptr, code.idx) @@ -2572,17 +2572,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(ptr)) + b = appendInt(b, ptrToInt64(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyInt64: @@ -2593,11 +2593,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2608,7 +2608,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagInt64: @@ -2619,10 +2619,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -2630,18 +2630,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadInt64Only, opStructFieldHeadInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt64Only, opStructFieldHeadOmitEmptyInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToInt64(p) + v := ptrToInt64(p) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2651,15 +2651,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt64Only, opStructFieldHeadStringTagInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadInt64Ptr: p := load(ctxptr, code.idx) @@ -2670,20 +2670,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyInt64Ptr: p := load(ctxptr, code.idx) @@ -2693,18 +2693,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagInt64Ptr: p := load(ctxptr, code.idx) @@ -2715,15 +2715,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } } @@ -2737,18 +2737,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -2760,16 +2760,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = encodeIndentComma(b) } code = code.next @@ -2781,19 +2781,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -2804,51 +2804,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2857,18 +2857,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagInt64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -2878,10 +2878,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -2890,11 +2890,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2907,17 +2907,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadInt64Ptr: p := load(ctxptr, code.idx) @@ -2925,19 +2925,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64Ptr: p := load(ctxptr, code.idx) @@ -2945,19 +2945,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagInt64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagInt64Ptr: p := load(ctxptr, code.idx) @@ -2965,15 +2965,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -2984,17 +2984,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadInt64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -3004,17 +3004,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyInt64PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -3024,24 +3024,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p+code.offset)) + b = appendInt(b, ptrToInt64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint: ptr := load(ctxptr, code.idx) @@ -3051,17 +3051,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint: @@ -3072,11 +3072,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3087,7 +3087,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint: @@ -3098,10 +3098,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -3109,18 +3109,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUintOnly, opStructFieldHeadUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUintOnly, opStructFieldHeadOmitEmptyUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := uint64(e.ptrToUint(p)) + v := uint64(ptrToUint(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -3130,15 +3130,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUintOnly, opStructFieldHeadStringTagUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUintPtr: p := load(ctxptr, code.idx) @@ -3149,20 +3149,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUintPtr: p := load(ctxptr, code.idx) @@ -3172,18 +3172,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUintPtr: p := load(ctxptr, code.idx) @@ -3194,15 +3194,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } } @@ -3216,18 +3216,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -3239,16 +3239,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -3260,19 +3260,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -3283,51 +3283,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3336,18 +3336,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagUint: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -3357,10 +3357,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -3369,11 +3369,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3386,17 +3386,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUintPtr: p := load(ctxptr, code.idx) @@ -3404,19 +3404,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUintPtr: p := load(ctxptr, code.idx) @@ -3424,19 +3424,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUintPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUintPtr: p := load(ctxptr, code.idx) @@ -3444,15 +3444,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -3463,17 +3463,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUintPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -3483,17 +3483,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUintPtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -3503,24 +3503,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p+code.offset))) + b = appendUint(b, uint64(ptrToUint(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint8: ptr := load(ctxptr, code.idx) @@ -3530,17 +3530,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(ptr))) + b = appendUint(b, uint64(ptrToUint8(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint8: @@ -3551,11 +3551,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3566,7 +3566,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint8: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint8: @@ -3577,10 +3577,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -3588,18 +3588,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUint8Only, opStructFieldHeadUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint8Only, opStructFieldHeadOmitEmptyUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := uint64(e.ptrToUint8(p)) + v := uint64(ptrToUint8(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -3609,15 +3609,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint8Only, opStructFieldHeadStringTagUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint8Ptr: p := load(ctxptr, code.idx) @@ -3628,20 +3628,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint8Ptr: p := load(ctxptr, code.idx) @@ -3651,18 +3651,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint8Ptr: p := load(ctxptr, code.idx) @@ -3673,15 +3673,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } } @@ -3695,18 +3695,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -3718,16 +3718,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -3739,19 +3739,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -3762,51 +3762,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3815,18 +3815,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagUint8: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint8: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -3836,10 +3836,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -3848,11 +3848,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3865,17 +3865,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint8Ptr: p := load(ctxptr, code.idx) @@ -3883,19 +3883,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8Ptr: p := load(ctxptr, code.idx) @@ -3903,19 +3903,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint8Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint8Ptr: p := load(ctxptr, code.idx) @@ -3923,15 +3923,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -3942,17 +3942,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint8PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -3962,17 +3962,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint8PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -3982,24 +3982,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p+code.offset))) + b = appendUint(b, uint64(ptrToUint8(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint16: ptr := load(ctxptr, code.idx) @@ -4009,17 +4009,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(ptr))) + b = appendUint(b, uint64(ptrToUint16(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint16: @@ -4030,11 +4030,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4045,7 +4045,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint16: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint16: @@ -4056,10 +4056,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -4067,18 +4067,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUint16Only, opStructFieldHeadUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint16Only, opStructFieldHeadOmitEmptyUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := uint64(e.ptrToUint16(p)) + v := uint64(ptrToUint16(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -4088,15 +4088,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint16Only, opStructFieldHeadStringTagUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint16Ptr: p := load(ctxptr, code.idx) @@ -4107,20 +4107,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint16Ptr: p := load(ctxptr, code.idx) @@ -4130,18 +4130,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint16Ptr: p := load(ctxptr, code.idx) @@ -4152,15 +4152,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } } @@ -4174,18 +4174,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -4197,16 +4197,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -4218,19 +4218,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -4241,51 +4241,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4294,18 +4294,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagUint16: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint16: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -4315,10 +4315,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -4327,11 +4327,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4344,17 +4344,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint16Ptr: p := load(ctxptr, code.idx) @@ -4362,19 +4362,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16Ptr: p := load(ctxptr, code.idx) @@ -4382,19 +4382,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint16Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint16Ptr: p := load(ctxptr, code.idx) @@ -4402,15 +4402,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -4421,17 +4421,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint16PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -4441,17 +4441,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint16PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -4461,24 +4461,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p+code.offset))) + b = appendUint(b, uint64(ptrToUint16(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint32: ptr := load(ctxptr, code.idx) @@ -4488,17 +4488,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(ptr))) + b = appendUint(b, uint64(ptrToUint32(ptr))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint32: @@ -4509,11 +4509,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4524,7 +4524,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint32: @@ -4535,10 +4535,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -4546,18 +4546,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUint32Only, opStructFieldHeadUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint32Only, opStructFieldHeadOmitEmptyUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := uint64(e.ptrToUint32(p)) + v := uint64(ptrToUint32(p)) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -4567,15 +4567,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint32Only, opStructFieldHeadStringTagUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint32Ptr: p := load(ctxptr, code.idx) @@ -4586,20 +4586,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint32Ptr: p := load(ctxptr, code.idx) @@ -4609,18 +4609,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint32Ptr: p := load(ctxptr, code.idx) @@ -4631,15 +4631,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } } @@ -4653,18 +4653,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -4676,16 +4676,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = encodeIndentComma(b) } code = code.next @@ -4697,19 +4697,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -4720,51 +4720,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4773,18 +4773,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagUint32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -4794,10 +4794,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -4806,11 +4806,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4823,17 +4823,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint32Ptr: p := load(ctxptr, code.idx) @@ -4841,19 +4841,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32Ptr: p := load(ctxptr, code.idx) @@ -4861,19 +4861,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint32Ptr: p := load(ctxptr, code.idx) @@ -4881,15 +4881,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) @@ -4900,17 +4900,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) } b = encodeIndentComma(b) code = code.next @@ -4920,17 +4920,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint32PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = encodeIndentComma(b) code = code.next } @@ -4940,24 +4940,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p+code.offset))) + b = appendUint(b, uint64(ptrToUint32(p+code.offset))) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint64: ptr := load(ctxptr, code.idx) @@ -4967,17 +4967,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(ptr)) + b = appendUint(b, ptrToUint64(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyUint64: @@ -4988,11 +4988,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -5003,7 +5003,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagUint64: @@ -5014,10 +5014,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -5025,18 +5025,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUint64Only, opStructFieldHeadUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint64Only, opStructFieldHeadOmitEmptyUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToUint64(p) + v := ptrToUint64(p) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -5046,15 +5046,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint64Only, opStructFieldHeadStringTagUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadUint64Ptr: p := load(ctxptr, code.idx) @@ -5065,20 +5065,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyUint64Ptr: p := load(ctxptr, code.idx) @@ -5088,18 +5088,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagUint64Ptr: p := load(ctxptr, code.idx) @@ -5110,15 +5110,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } } @@ -5132,18 +5132,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -5155,16 +5155,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = encodeIndentComma(b) } code = code.next @@ -5176,19 +5176,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -5199,51 +5199,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -5252,18 +5252,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagUint64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -5273,10 +5273,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -5285,11 +5285,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -5302,17 +5302,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadUint64Ptr: p := load(ctxptr, code.idx) @@ -5320,19 +5320,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64Ptr: p := load(ctxptr, code.idx) @@ -5340,19 +5340,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagUint64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagUint64Ptr: p := load(ctxptr, code.idx) @@ -5360,15 +5360,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -5379,17 +5379,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadUint64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -5399,17 +5399,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyUint64PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -5419,24 +5419,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p+code.offset)) + b = appendUint(b, ptrToUint64(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat32: ptr := load(ctxptr, code.idx) @@ -5446,17 +5446,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(ptr)) + b = encodeFloat32(b, ptrToFloat32(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyFloat32: @@ -5467,11 +5467,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5482,7 +5482,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagFloat32: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagFloat32: @@ -5493,10 +5493,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -5504,18 +5504,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadFloat32Only, opStructFieldHeadFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat32Only, opStructFieldHeadOmitEmptyFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToFloat32(p) + v := ptrToFloat32(p) if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5525,15 +5525,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagFloat32Only, opStructFieldHeadStringTagFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat32Ptr: p := load(ctxptr, code.idx) @@ -5544,20 +5544,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyFloat32Ptr: p := load(ctxptr, code.idx) @@ -5567,18 +5567,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagFloat32Ptr: p := load(ctxptr, code.idx) @@ -5589,15 +5589,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } } @@ -5611,18 +5611,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = encodeIndentComma(b) code = code.next @@ -5634,16 +5634,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = encodeIndentComma(b) } code = code.next @@ -5655,19 +5655,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -5678,51 +5678,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(ptr)) + b = encodeFloat32(b, ptrToFloat32(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5731,18 +5731,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagFloat32: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat32: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -5752,10 +5752,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(ptr)) + b = encodeFloat32(b, ptrToFloat32(ptr)) b = encodeIndentComma(b) code = code.next } @@ -5764,11 +5764,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5781,17 +5781,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat32Ptr: p := load(ctxptr, code.idx) @@ -5799,19 +5799,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32Ptr: p := load(ctxptr, code.idx) @@ -5819,19 +5819,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagFloat32Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat32Ptr: p := load(ctxptr, code.idx) @@ -5839,15 +5839,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) @@ -5858,17 +5858,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadFloat32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } b = encodeIndentComma(b) code = code.next @@ -5878,17 +5878,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat32PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -5898,24 +5898,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p+code.offset)) + b = encodeFloat32(b, ptrToFloat32(p+code.offset)) b = append(b, '"') } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat64: ptr := load(ctxptr, code.idx) @@ -5924,12 +5924,12 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.end.next } else { - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -5939,7 +5939,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadOmitEmptyFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyFloat64: @@ -5950,14 +5950,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -5968,7 +5968,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagFloat64: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagFloat64: @@ -5979,10 +5979,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -5994,10 +5994,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadFloat64Only, opStructFieldHeadFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6007,12 +6007,12 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadOmitEmptyFloat64Only, opStructFieldHeadOmitEmptyFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } if v != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -6022,10 +6022,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagFloat64Only, opStructFieldHeadStringTagFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6034,7 +6034,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadFloat64Ptr: p := load(ctxptr, code.idx) @@ -6045,14 +6045,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6062,7 +6062,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyFloat64Ptr: p := load(ctxptr, code.idx) @@ -6072,12 +6072,12 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6087,7 +6087,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next } case opStructFieldPtrHeadStringTagFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagFloat64Ptr: p := load(ctxptr, code.idx) @@ -6098,15 +6098,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6124,18 +6124,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6151,16 +6151,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6176,19 +6176,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6203,19 +6203,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6225,17 +6225,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6244,21 +6244,21 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -6267,18 +6267,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagFloat64: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat64: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6292,10 +6292,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6308,14 +6308,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6329,11 +6329,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') - v := e.ptrToFloat64(ptr) + v := ptrToFloat64(ptr) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6343,7 +6343,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next } case opStructFieldPtrAnonymousHeadFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadFloat64Ptr: p := load(ctxptr, code.idx) @@ -6351,14 +6351,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6367,7 +6367,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64Ptr: p := load(ctxptr, code.idx) @@ -6375,14 +6375,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6391,7 +6391,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next } case opStructFieldPtrAnonymousHeadStringTagFloat64Ptr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagFloat64Ptr: p := load(ctxptr, code.idx) @@ -6399,15 +6399,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6422,17 +6422,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadFloat64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6446,17 +6446,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyFloat64PtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6470,18 +6470,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -6491,7 +6491,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadString: ptr := load(ctxptr, code.idx) @@ -6501,17 +6501,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(ptr)) + b = encodeNoEscapedString(b, ptrToString(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyString: @@ -6522,11 +6522,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -6537,7 +6537,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagString: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagString: @@ -6548,10 +6548,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, v))) b = encodeIndentComma(b) code = code.next @@ -6559,18 +6559,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringOnly, opStructFieldHeadStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyStringOnly, opStructFieldHeadOmitEmptyStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - v := e.ptrToString(p) + v := ptrToString(p) if v != "" { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -6580,14 +6580,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagStringOnly, opStructFieldHeadStringTagStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringPtr: p := load(ctxptr, code.idx) @@ -6598,20 +6598,20 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadOmitEmptyStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadOmitEmptyStringPtr: p := load(ctxptr, code.idx) @@ -6621,18 +6621,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeIndentComma(b) } code = code.next } case opStructFieldPtrHeadStringTagStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadStringTagStringPtr: p := load(ctxptr, code.idx) @@ -6643,14 +6643,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) } } b = encodeIndentComma(b) @@ -6663,18 +6663,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -6686,16 +6686,16 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadOmitEmptyStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) b = encodeIndentComma(b) } code = code.next @@ -6707,18 +6707,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p+code.offset)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p+code.offset)))) } b = encodeIndentComma(b) code = code.next @@ -6728,51 +6728,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { if p == 0 { break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) } if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadString: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadOmitEmptyString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyString: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -6781,17 +6781,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } } case opStructFieldPtrAnonymousHeadStringTagString: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagString: ptr := load(ctxptr, code.idx) if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(ptr+code.offset)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(ptr+code.offset)))) b = encodeIndentComma(b) code = code.next } @@ -6800,10 +6800,10 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -6812,11 +6812,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v == "" { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -6829,15 +6829,15 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(ptr+code.offset)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(ptr+code.offset)))) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringPtr: p := load(ctxptr, code.idx) @@ -6845,19 +6845,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrAnonymousHeadOmitEmptyStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadOmitEmptyStringPtr: p := load(ctxptr, code.idx) @@ -6865,19 +6865,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrAnonymousHeadStringTagStringPtr: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldAnonymousHeadStringTagStringPtr: p := load(ctxptr, code.idx) @@ -6885,14 +6885,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - p = e.ptrToPtr(p) + p = ptrToPtr(p) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p+code.offset)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p+code.offset)))) } b = encodeIndentComma(b) code = code.next @@ -6902,17 +6902,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) } b = encodeIndentComma(b) code = code.next @@ -6922,17 +6922,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadOmitEmptyStringPtrOnly: p := load(ctxptr, code.idx) if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(p+code.offset)) + b = encodeNoEscapedString(b, ptrToString(p+code.offset)) b = encodeIndentComma(b) code = code.next } @@ -6942,81 +6942,81 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - store(ctxptr, code.idx, e.ptrToPtr(p)) + store(ctxptr, code.idx, ptrToPtr(p)) fallthrough case opStructFieldAnonymousHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p+code.offset)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p+code.offset)))) } b = encodeIndentComma(b) code = code.next case opStructFieldPtrHeadBool: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeBool(b, e.ptrToBool(ptr)) + b = encodeBool(b, ptrToBool(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadBytes: - store(ctxptr, code.idx, e.ptrToPtr(load(ctxptr, code.idx))) + store(ctxptr, code.idx, ptrToPtr(load(ctxptr, code.idx))) fallthrough case opStructFieldHeadBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeByteSlice(b, e.ptrToBytes(ptr)) + b = encodeByteSlice(b, ptrToBytes(ptr)) b = encodeIndentComma(b) code = code.next } case opStructFieldPtrHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if !v { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeBool(b, v) @@ -7027,24 +7027,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '{', '\n') - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -7055,7 +7055,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTag: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTag: @@ -7067,7 +7067,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } else { b = append(b, '{', '\n') p := ptr + code.offset - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') code = code.next @@ -7076,22 +7076,22 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next @@ -7099,27 +7099,27 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr != 0 { - store(ctxptr, code.idx, e.ptrToPtr(ptr)) + store(ctxptr, code.idx, ptrToPtr(ptr)) } fallthrough case opStructFieldHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { b = append(b, '{', '\n') - b = e.encodeIndent(b, code.indent+1) + b = encodeIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeIndentComma(b) code = code.next } case opStructField: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7132,7 +7132,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 || **(**uintptr)(unsafe.Pointer(&p)) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next @@ -7141,24 +7141,24 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldStringTag: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next store(ctxptr, code.idx, p) case opStructFieldInt: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7167,26 +7167,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldInt8: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7195,26 +7195,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt8: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldInt16: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7223,26 +7223,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt16: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldInt32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7251,26 +7251,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldInt64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyInt64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -7279,26 +7279,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt64: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7307,26 +7307,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint8: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7335,26 +7335,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint8: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint16: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7363,26 +7363,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint16: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7391,26 +7391,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldUint64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyUint64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -7419,26 +7419,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint64: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldFloat32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyFloat32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -7447,19 +7447,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagFloat32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldFloat64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } @@ -7468,12 +7468,12 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldOmitEmptyFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v != 0 { if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -7482,11 +7482,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeFloat64(b, v) @@ -7494,18 +7494,18 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldString: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyString: ptr := load(ctxptr, code.headIdx) - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v != "" { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -7514,63 +7514,63 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagString: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, s))) b = encodeIndentComma(b) code = code.next case opStructFieldStringPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) } b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyStringPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) b = encodeIndentComma(b) } code = code.next case opStructFieldStringTagStringPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) } b = encodeIndentComma(b) code = code.next case opStructFieldBool: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyBool: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if v { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeBool(b, v) @@ -7579,26 +7579,26 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagBool: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') b = encodeIndentComma(b) code = code.next case opStructFieldBytes: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldOmitEmptyBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) > 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -7607,19 +7607,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagBytes: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldMarshalJSON: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -7632,8 +7632,8 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } @@ -7642,11 +7642,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -7659,8 +7659,8 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } @@ -7669,11 +7669,11 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagMarshalText: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) @@ -7682,12 +7682,12 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldArray: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - array := e.ptrToSlice(p) + array := ptrToSlice(p) if p == 0 || uintptr(array.data) == 0 { b = encodeNull(b) b = encodeIndentComma(b) @@ -7698,22 +7698,22 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldOmitEmptyArray: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - array := e.ptrToSlice(p) + array := ptrToSlice(p) if p == 0 || uintptr(array.data) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next } case opStructFieldSlice: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) if p == 0 || uintptr(slice.data) == 0 { b = encodeNull(b) b = encodeIndentComma(b) @@ -7724,17 +7724,17 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldOmitEmptySlice: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - slice := e.ptrToSlice(p) + slice := ptrToSlice(p) if p == 0 || uintptr(slice.data) == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next } case opStructFieldMap: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7743,8 +7743,8 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) code = code.nextField } else { - p = e.ptrToPtr(p) - mlen := maplen(e.ptrToUnsafePtr(p)) + p = ptrToPtr(p) + mlen := maplen(ptrToUnsafePtr(p)) if mlen == 0 { b = append(b, '{', '}', ',', '\n') mapCode := code.next @@ -7763,14 +7763,14 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if mlen == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next } } case opStructFieldMapLoad: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7779,8 +7779,8 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) code = code.nextField } else { - p = e.ptrToPtr(p) - mlen := maplen(e.ptrToUnsafePtr(p)) + p = ptrToPtr(p) + mlen := maplen(ptrToUnsafePtr(p)) if mlen == 0 { b = append(b, '{', '}', ',', '\n') code = code.nextField @@ -7798,7 +7798,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if mlen == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next @@ -7807,7 +7807,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldStruct: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -7830,7 +7830,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') headCode := code.next @@ -7858,27 +7858,27 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') b = encodeIndentComma(b) code = code.next case opStructEndInt: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt(ptr + code.offset) + v := ptrToInt(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -7889,7 +7889,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -7897,35 +7897,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndIntPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyIntPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -7936,44 +7936,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagIntPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt(p))) + b = appendInt(b, int64(ptrToInt(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt8: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt8(ptr + code.offset) + v := ptrToInt8(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -7984,7 +7984,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -7992,35 +7992,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt8: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt8(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt8Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt8Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt8(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt8(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8031,44 +8031,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt8Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt8(p))) + b = appendInt(b, int64(ptrToInt8(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt16: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt16(ptr + code.offset) + v := ptrToInt16(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8079,7 +8079,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8087,35 +8087,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt16: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt16(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt16Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt16Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt16(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt16(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8126,44 +8126,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt16Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt16(p))) + b = appendInt(b, int64(ptrToInt16(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt32(ptr + code.offset) + v := ptrToInt32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8174,7 +8174,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8182,35 +8182,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, int64(e.ptrToInt32(ptr+code.offset))) + b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, int64(e.ptrToInt32(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, int64(ptrToInt32(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8221,44 +8221,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, int64(e.ptrToInt32(p))) + b = appendInt(b, int64(ptrToInt32(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, ptrToInt64(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToInt64(ptr + code.offset) + v := ptrToInt64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8269,7 +8269,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8277,35 +8277,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt64: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendInt(b, e.ptrToInt64(ptr+code.offset)) + b = appendInt(b, ptrToInt64(ptr+code.offset)) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyInt64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendInt(b, e.ptrToInt64(p)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendInt(b, ptrToInt64(p)) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8316,44 +8316,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendInt(b, e.ptrToInt64(p)) + b = appendInt(b, ptrToInt64(p)) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint(ptr + code.offset) + v := ptrToUint(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8364,7 +8364,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8372,35 +8372,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUintPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUintPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8411,44 +8411,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUintPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint(p))) + b = appendUint(b, uint64(ptrToUint(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint8: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint8: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint8(ptr + code.offset) + v := ptrToUint8(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8459,7 +8459,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8467,35 +8467,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint8: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint8(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint8Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint8Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint8(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint8(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8506,44 +8506,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint8Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint8(p))) + b = appendUint(b, uint64(ptrToUint8(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint16: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint16: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint16(ptr + code.offset) + v := ptrToUint16(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8554,7 +8554,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8562,35 +8562,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint16: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint16(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint16Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint16Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint16(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint16(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8601,44 +8601,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint16Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint16(p))) + b = appendUint(b, uint64(ptrToUint16(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint32(ptr + code.offset) + v := ptrToUint32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8649,7 +8649,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8657,35 +8657,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, uint64(e.ptrToUint32(ptr+code.offset))) + b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, uint64(e.ptrToUint32(p))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, uint64(ptrToUint32(p))) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8696,44 +8696,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, uint64(e.ptrToUint32(p))) + b = appendUint(b, uint64(ptrToUint32(p))) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, ptrToUint64(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToUint64(ptr + code.offset) + v := ptrToUint64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8744,7 +8744,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8752,35 +8752,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint64: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = appendUint(b, e.ptrToUint64(ptr+code.offset)) + b = appendUint(b, ptrToUint64(ptr+code.offset)) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyUint64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = appendUint(b, e.ptrToUint64(p)) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendUint(b, ptrToUint64(p)) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8791,44 +8791,44 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = appendUint(b, e.ptrToUint64(p)) + b = appendUint(b, ptrToUint64(p)) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat32: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyFloat32: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat32(ptr + code.offset) + v := ptrToFloat32(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8839,7 +8839,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8847,35 +8847,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagFloat32: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = encodeFloat32(b, e.ptrToFloat32(ptr+code.offset)) + b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyFloat32Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeFloat32(b, e.ptrToFloat32(p)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeFloat32(b, ptrToFloat32(p)) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8886,51 +8886,51 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagFloat32Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - b = encodeFloat32(b, e.ptrToFloat32(p)) + b = encodeFloat32(b, ptrToFloat32(p)) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat64: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if v != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -8941,7 +8941,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8949,47 +8949,47 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagFloat64: ptr := load(ctxptr, code.headIdx) - v := e.ptrToFloat64(ptr + code.offset) + v := ptrToFloat64(ptr + code.offset) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeFloat64(b, v) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyFloat64Ptr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9000,48 +9000,48 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagFloat64Ptr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { b = append(b, '"') - v := e.ptrToFloat64(p) + v := ptrToFloat64(p) if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } b = encodeFloat64(b, v) b = append(b, '"') } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndString: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeNoEscapedString(b, e.ptrToString(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyString: ptr := load(ctxptr, code.headIdx) - v := e.ptrToString(ptr + code.offset) + v := ptrToString(ptr + code.offset) if v != "" { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9052,7 +9052,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9060,35 +9060,35 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagString: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - s := e.ptrToString(ptr + code.offset) + s := ptrToString(ptr + code.offset) b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, s))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndStringPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, e.ptrToString(p)) + b = encodeNoEscapedString(b, ptrToString(p)) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyStringPtr: ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p != 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeNoEscapedString(b, e.ptrToString(p)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeNoEscapedString(b, ptrToString(p)) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9099,42 +9099,42 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagStringPtr: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - p := e.ptrToPtr(ptr + code.offset) + p := ptrToPtr(ptr + code.offset) if p == 0 { b = encodeNull(b) } else { - b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, e.ptrToString(p)))) + b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) } - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndBool: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeBool(b, ptrToBool(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyBool: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBool(ptr + code.offset) + v := ptrToBool(ptr + code.offset) if v { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeBool(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9145,7 +9145,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9153,30 +9153,30 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagBool: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') - b = encodeBool(b, e.ptrToBool(ptr+code.offset)) + b = encodeBool(b, ptrToBool(ptr+code.offset)) b = append(b, '"') - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndBytes: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndOmitEmptyBytes: ptr := load(ctxptr, code.headIdx) - v := e.ptrToBytes(ptr + code.offset) + v := ptrToBytes(ptr + code.offset) if len(v) > 0 { - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, v) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) } else { last := len(b) - 1 if b[last-1] == '{' { @@ -9187,7 +9187,7 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9195,19 +9195,19 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagBytes: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') - b = encodeByteSlice(b, e.ptrToBytes(ptr+code.offset)) - b = e.appendStructEndIndent(b, code.indent-1) + b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndMarshalJSON: - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9220,21 +9220,21 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } b = append(b, indentBuf.Bytes()...) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bb, err := v.(Marshaler).MarshalJSON() if err != nil { return nil, errMarshaler(code, err) @@ -9247,27 +9247,27 @@ func (e *Encoder) runIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if err := encodeWithIndent( &indentBuf, compactBuf.Bytes(), - string(e.prefix)+strings.Repeat(string(e.indentStr), e.baseIndent+code.indent), - string(e.indentStr), + string(ctx.prefix)+strings.Repeat(string(ctx.indentStr), ctx.baseIndent+code.indent), + string(ctx.indentStr), ); err != nil { return nil, err } b = encodeNoEscapedString(b, indentBuf.String()) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndStringTagMarshalText: ptr := load(ctxptr, code.headIdx) - b = e.encodeIndent(b, code.indent) + b = encodeIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset - v := e.ptrToInterface(code, p) + v := ptrToInterface(code, p) bytes, err := v.(encoding.TextMarshaler).MarshalText() if err != nil { return nil, errMarshaler(code, err) } b = encodeNoEscapedString(b, *(*string)(unsafe.Pointer(&bytes))) - b = e.appendStructEndIndent(b, code.indent-1) + b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opEnd: goto END diff --git a/json.go b/json.go index f3a3f3a..662739b 100644 --- a/json.go +++ b/json.go @@ -4,7 +4,6 @@ import ( "bytes" "errors" "strconv" - "unsafe" ) // Marshaler is the interface implemented by types that @@ -160,34 +159,16 @@ func Marshal(v interface{}) ([]byte, error) { // MarshalNoEscape func MarshalNoEscape(v interface{}) ([]byte, error) { - enc := newEncoder() - header := (*interfaceHeader)(unsafe.Pointer(&v)) - bytes, err := enc.encodeForMarshal(header, v == nil) - if err != nil { - enc.release() - return nil, err - } - enc.release() - return bytes, nil + return marshal(v, EncodeOptionHTMLEscape) } // MarshalWithOption returns the JSON encoding of v with EncodeOption. -func MarshalWithOption(v interface{}, opts ...EncodeOption) ([]byte, error) { - enc := newEncoder() - for _, opt := range opts { - if err := opt(enc); err != nil { - return nil, err - } +func MarshalWithOption(v interface{}, optFuncs ...EncodeOptionFunc) ([]byte, error) { + opt := EncodeOptionHTMLEscape + for _, optFunc := range optFuncs { + opt = optFunc(opt) } - header := (*interfaceHeader)(unsafe.Pointer(&v)) - enc.ptr = header.ptr - bytes, err := enc.encodeForMarshal(header, v == nil) - if err != nil { - enc.release() - return nil, err - } - enc.release() - return bytes, nil + return marshal(v, opt) } // MarshalIndent is like Marshal but applies Indent to format the output. @@ -198,24 +179,12 @@ func MarshalIndent(v interface{}, prefix, indent string) ([]byte, error) { } // MarshalIndentWithOption is like Marshal but applies Indent to format the output with EncodeOption. -func MarshalIndentWithOption(v interface{}, prefix, indent string, opts ...EncodeOption) ([]byte, error) { - var b *bytes.Buffer - enc := NewEncoder(b) - for _, opt := range opts { - if err := opt(enc); err != nil { - return nil, err - } +func MarshalIndentWithOption(v interface{}, prefix, indent string, optFuncs ...EncodeOptionFunc) ([]byte, error) { + opt := EncodeOptionHTMLEscape | EncodeOptionIndent + for _, optFunc := range optFuncs { + opt = optFunc(opt) } - enc.SetIndent(prefix, indent) - header := (*interfaceHeader)(unsafe.Pointer(&v)) - enc.ptr = header.ptr - bytes, err := enc.encodeForMarshal(header, v == nil) - if err != nil { - enc.release() - return nil, err - } - enc.release() - return bytes, nil + return marshalIndent(v, prefix, indent, opt) } // Unmarshal parses the JSON-encoded data and stores the result @@ -408,12 +377,8 @@ func HTMLEscape(dst *bytes.Buffer, src []byte) { if err := dec.Decode(&v); err != nil { return } - enc := NewEncoder(dst) - enc.SetEscapeHTML(true) - header := (*interfaceHeader)(unsafe.Pointer(&v)) - enc.ptr = header.ptr - enc.buf, _ = enc.encode(header, v == nil) - dst.Write(enc.buf[:len(enc.buf)-1]) // remove last ',' character + buf, _ := marshal(v, EncodeOptionHTMLEscape) + dst.Write(buf) } // Valid reports whether data is a valid JSON encoding. diff --git a/option.go b/option.go index b2414a7..3f3e919 100644 --- a/option.go +++ b/option.go @@ -1,10 +1,9 @@ package json -type EncodeOption func(*Encoder) error +type EncodeOptionFunc func(EncodeOption) EncodeOption -func UnorderedMap() EncodeOption { - return func(e *Encoder) error { - e.unorderedMap = true - return nil +func UnorderedMap() func(EncodeOption) EncodeOption { + return func(opt EncodeOption) EncodeOption { + return opt | EncodeOptionUnorderedMap } } From ffc954d3569b474f9007babbf4f1a59378ca4972 Mon Sep 17 00:00:00 2001 From: Masaaki Goshima Date: Sun, 31 Jan 2021 22:53:01 +0900 Subject: [PATCH 2/6] Fix MarshalNoEscape --- encode.go | 47 +++++++++++++++++++++++++++++++++++++++++++++++ json.go | 2 +- 2 files changed, 48 insertions(+), 1 deletion(-) diff --git a/encode.go b/encode.go index a9fc6c7..aab231a 100644 --- a/encode.go +++ b/encode.go @@ -133,6 +133,23 @@ func marshal(v interface{}, opt EncodeOption) ([]byte, error) { return copied, nil } +func marshalNoEscape(v interface{}, opt EncodeOption) ([]byte, error) { + buf, err := encodeNoEscapeWithOpt(v, EncodeOptionHTMLEscape) + if err != nil { + return nil, err + } + + // this line exists to escape call of `runtime.makeslicecopy` . + // if use `make([]byte, len(buf)-1)` and `copy(copied, buf)`, + // dst buffer size and src buffer size are differrent. + // in this case, compiler uses `runtime.makeslicecopy`, but it is slow. + buf = buf[:len(buf)-1] + + copied := make([]byte, len(buf)) + copy(copied, buf) + return copied, nil +} + func marshalIndent(v interface{}, prefix, indent string, opt EncodeOption) ([]byte, error) { buf, err := encodeIndentWithOpt(v, prefix, indent, EncodeOptionHTMLEscape) if err != nil { @@ -178,6 +195,36 @@ func encodeWithOpt(v interface{}, opt EncodeOption) ([]byte, error) { return buf, nil } +func encodeNoEscapeWithOpt(v interface{}, opt EncodeOption) ([]byte, error) { + ctx := takeEncodeRuntimeContext() + b := ctx.buf[:0] + if v == nil { + b = encodeNull(b) + b = encodeComma(b) + return b, nil + } + header := (*interfaceHeader)(unsafe.Pointer(&v)) + typ := header.typ + + typeptr := uintptr(unsafe.Pointer(typ)) + codeSet, err := encodeCompileToGetCodeSet(typeptr) + if err != nil { + return nil, err + } + + p := uintptr(header.ptr) + ctx.init(p, codeSet.codeLength) + buf, err := encodeRunCode(ctx, b, codeSet, opt) + if err != nil { + releaseEncodeRuntimeContext(ctx) + return nil, err + } + + ctx.buf = buf + releaseEncodeRuntimeContext(ctx) + return buf, nil +} + func encodeIndentWithOpt(v interface{}, prefix, indent string, opt EncodeOption) ([]byte, error) { ctx := takeEncodeRuntimeContext() b := ctx.buf[:0] diff --git a/json.go b/json.go index 662739b..ee21941 100644 --- a/json.go +++ b/json.go @@ -159,7 +159,7 @@ func Marshal(v interface{}) ([]byte, error) { // MarshalNoEscape func MarshalNoEscape(v interface{}) ([]byte, error) { - return marshal(v, EncodeOptionHTMLEscape) + return marshalNoEscape(v, EncodeOptionHTMLEscape) } // MarshalWithOption returns the JSON encoding of v with EncodeOption. From 7895767eaa1ad691be5e6a191f983bb4ef5c4331 Mon Sep 17 00:00:00 2001 From: Masaaki Goshima Date: Sun, 31 Jan 2021 23:01:39 +0900 Subject: [PATCH 3/6] Add benchmark for streaming encoding --- benchmarks/encode_test.go | 54 ++++++++++++++++++++++++++++++++++++--- 1 file changed, 50 insertions(+), 4 deletions(-) diff --git a/benchmarks/encode_test.go b/benchmarks/encode_test.go index 47c76db..619c496 100644 --- a/benchmarks/encode_test.go +++ b/benchmarks/encode_test.go @@ -1,6 +1,7 @@ package benchmark import ( + "bytes" "encoding/json" "testing" @@ -559,6 +560,51 @@ func Benchmark_Encode_Interface_GoJson(b *testing.B) { } func Benchmark_Encode_Bool_EncodingJson(b *testing.B) { + b.ReportAllocs() + var buf bytes.Buffer + enc := json.NewEncoder(&buf) + for i := 0; i < b.N; i++ { + if err := enc.Encode(true); err != nil { + b.Fatal(err) + } + } +} + +func Benchmark_Encode_Bool_JsonIter(b *testing.B) { + var json = jsoniter.ConfigCompatibleWithStandardLibrary + b.ReportAllocs() + var buf bytes.Buffer + enc := json.NewEncoder(&buf) + for i := 0; i < b.N; i++ { + if err := enc.Encode(true); err != nil { + b.Fatal(err) + } + } +} + +func Benchmark_Encode_Bool_SegmentioJson(b *testing.B) { + b.ReportAllocs() + var buf bytes.Buffer + enc := segmentiojson.NewEncoder(&buf) + for i := 0; i < b.N; i++ { + if err := enc.Encode(true); err != nil { + b.Fatal(err) + } + } +} + +func Benchmark_Encode_Bool_GoJson(b *testing.B) { + b.ReportAllocs() + var buf bytes.Buffer + enc := gojson.NewEncoder(&buf) + for i := 0; i < b.N; i++ { + if err := enc.Encode(true); err != nil { + b.Fatal(err) + } + } +} + +func Benchmark_Marshal_Bool_EncodingJson(b *testing.B) { b.ReportAllocs() for i := 0; i < b.N; i++ { if _, err := json.Marshal(true); err != nil { @@ -567,7 +613,7 @@ func Benchmark_Encode_Bool_EncodingJson(b *testing.B) { } } -func Benchmark_Encode_Bool_JsonIter(b *testing.B) { +func Benchmark_Marshal_Bool_JsonIter(b *testing.B) { var json = jsoniter.ConfigCompatibleWithStandardLibrary b.ReportAllocs() for i := 0; i < b.N; i++ { @@ -577,7 +623,7 @@ func Benchmark_Encode_Bool_JsonIter(b *testing.B) { } } -func Benchmark_Encode_Bool_Jettison(b *testing.B) { +func Benchmark_Marshal_Bool_Jettison(b *testing.B) { b.ReportAllocs() for i := 0; i < b.N; i++ { if _, err := jettison.Marshal(true); err != nil { @@ -586,7 +632,7 @@ func Benchmark_Encode_Bool_Jettison(b *testing.B) { } } -func Benchmark_Encode_Bool_SegmentioJson(b *testing.B) { +func Benchmark_Marshal_Bool_SegmentioJson(b *testing.B) { b.ReportAllocs() for i := 0; i < b.N; i++ { if _, err := segmentiojson.Marshal(true); err != nil { @@ -595,7 +641,7 @@ func Benchmark_Encode_Bool_SegmentioJson(b *testing.B) { } } -func Benchmark_Encode_Bool_GoJson(b *testing.B) { +func Benchmark_Marshal_Bool_GoJson(b *testing.B) { b.ReportAllocs() for i := 0; i < b.N; i++ { if _, err := gojson.Marshal(true); err != nil { From 48b6fe21c6dd36d466810278d3f4753ff46718ff Mon Sep 17 00:00:00 2001 From: Masaaki Goshima Date: Mon, 1 Feb 2021 11:36:41 +0900 Subject: [PATCH 4/6] Fix race error --- encode.go | 55 +- encode_vm_escaped_indent.go | 1108 +++++++++++++++++------------------ encode_vm_indent.go | 1108 +++++++++++++++++------------------ 3 files changed, 1142 insertions(+), 1129 deletions(-) diff --git a/encode.go b/encode.go index aab231a..ad6aa78 100644 --- a/encode.go +++ b/encode.go @@ -65,6 +65,15 @@ func (e *Encoder) Encode(v interface{}) error { // EncodeWithOption call Encode with EncodeOption. func (e *Encoder) EncodeWithOption(v interface{}, optFuncs ...EncodeOptionFunc) error { + ctx := takeEncodeRuntimeContext() + + err := e.encodeWithOption(ctx, v, optFuncs...) + + releaseEncodeRuntimeContext(ctx) + return err +} + +func (e *Encoder) encodeWithOption(ctx *encodeRuntimeContext, v interface{}, optFuncs ...EncodeOptionFunc) error { var opt EncodeOption if e.enabledHTMLEscape { opt |= EncodeOptionHTMLEscape @@ -77,9 +86,9 @@ func (e *Encoder) EncodeWithOption(v interface{}, optFuncs ...EncodeOptionFunc) err error ) if e.enabledIndent { - buf, err = encodeIndentWithOpt(v, e.prefix, e.indentStr, opt) + buf, err = encodeIndent(ctx, v, e.prefix, e.indentStr, opt) } else { - buf, err = encodeWithOpt(v, opt) + buf, err = encode(ctx, v, opt) } if err != nil { return err @@ -117,8 +126,11 @@ func (e *Encoder) SetIndent(prefix, indent string) { } func marshal(v interface{}, opt EncodeOption) ([]byte, error) { - buf, err := encodeWithOpt(v, EncodeOptionHTMLEscape) + ctx := takeEncodeRuntimeContext() + + buf, err := encode(ctx, v, EncodeOptionHTMLEscape) if err != nil { + releaseEncodeRuntimeContext(ctx) return nil, err } @@ -127,15 +139,19 @@ func marshal(v interface{}, opt EncodeOption) ([]byte, error) { // dst buffer size and src buffer size are differrent. // in this case, compiler uses `runtime.makeslicecopy`, but it is slow. buf = buf[:len(buf)-1] - copied := make([]byte, len(buf)) copy(copied, buf) + + releaseEncodeRuntimeContext(ctx) return copied, nil } func marshalNoEscape(v interface{}, opt EncodeOption) ([]byte, error) { - buf, err := encodeNoEscapeWithOpt(v, EncodeOptionHTMLEscape) + ctx := takeEncodeRuntimeContext() + + buf, err := encodeNoEscape(ctx, v, EncodeOptionHTMLEscape) if err != nil { + releaseEncodeRuntimeContext(ctx) return nil, err } @@ -144,26 +160,31 @@ func marshalNoEscape(v interface{}, opt EncodeOption) ([]byte, error) { // dst buffer size and src buffer size are differrent. // in this case, compiler uses `runtime.makeslicecopy`, but it is slow. buf = buf[:len(buf)-1] - copied := make([]byte, len(buf)) copy(copied, buf) + + releaseEncodeRuntimeContext(ctx) return copied, nil } func marshalIndent(v interface{}, prefix, indent string, opt EncodeOption) ([]byte, error) { - buf, err := encodeIndentWithOpt(v, prefix, indent, EncodeOptionHTMLEscape) + ctx := takeEncodeRuntimeContext() + + buf, err := encodeIndent(ctx, v, prefix, indent, EncodeOptionHTMLEscape) if err != nil { + releaseEncodeRuntimeContext(ctx) return nil, err } - buf = buf[:len(buf)-2] + buf = buf[:len(buf)-2] copied := make([]byte, len(buf)) copy(copied, buf) + + releaseEncodeRuntimeContext(ctx) return copied, nil } -func encodeWithOpt(v interface{}, opt EncodeOption) ([]byte, error) { - ctx := takeEncodeRuntimeContext() +func encode(ctx *encodeRuntimeContext, v interface{}, opt EncodeOption) ([]byte, error) { b := ctx.buf[:0] if v == nil { b = encodeNull(b) @@ -186,17 +207,14 @@ func encodeWithOpt(v interface{}, opt EncodeOption) ([]byte, error) { ctx.keepRefs = append(ctx.keepRefs, header.ptr) if err != nil { - releaseEncodeRuntimeContext(ctx) return nil, err } ctx.buf = buf - releaseEncodeRuntimeContext(ctx) return buf, nil } -func encodeNoEscapeWithOpt(v interface{}, opt EncodeOption) ([]byte, error) { - ctx := takeEncodeRuntimeContext() +func encodeNoEscape(ctx *encodeRuntimeContext, v interface{}, opt EncodeOption) ([]byte, error) { b := ctx.buf[:0] if v == nil { b = encodeNull(b) @@ -216,17 +234,14 @@ func encodeNoEscapeWithOpt(v interface{}, opt EncodeOption) ([]byte, error) { ctx.init(p, codeSet.codeLength) buf, err := encodeRunCode(ctx, b, codeSet, opt) if err != nil { - releaseEncodeRuntimeContext(ctx) return nil, err } ctx.buf = buf - releaseEncodeRuntimeContext(ctx) return buf, nil } -func encodeIndentWithOpt(v interface{}, prefix, indent string, opt EncodeOption) ([]byte, error) { - ctx := takeEncodeRuntimeContext() +func encodeIndent(ctx *encodeRuntimeContext, v interface{}, prefix, indent string, opt EncodeOption) ([]byte, error) { b := ctx.buf[:0] if v == nil { b = encodeNull(b) @@ -249,12 +264,10 @@ func encodeIndentWithOpt(v interface{}, prefix, indent string, opt EncodeOption) ctx.keepRefs = append(ctx.keepRefs, header.ptr) if err != nil { - releaseEncodeRuntimeContext(ctx) return nil, err } ctx.buf = buf - releaseEncodeRuntimeContext(ctx) return buf, nil } @@ -349,7 +362,7 @@ func encodeByteSlice(b []byte, src []byte) []byte { return append(append(b, buf...), '"') } -func encodeIndent(ctx *encodeRuntimeContext, b []byte, indent int) []byte { +func appendIndent(ctx *encodeRuntimeContext, b []byte, indent int) []byte { b = append(b, ctx.prefix...) return append(b, bytes.Repeat(ctx.indentStr, ctx.baseIndent+indent)...) } diff --git a/encode_vm_escaped_indent.go b/encode_vm_escaped_indent.go index 1c62cf7..26b2b22 100644 --- a/encode_vm_escaped_indent.go +++ b/encode_vm_escaped_indent.go @@ -277,7 +277,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opSliceHead: p := load(ctxptr, code.idx) if p == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -288,11 +288,11 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode store(ctxptr, code.idx, uintptr(slice.data)) if slice.len > 0 { b = append(b, '[', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) code = code.next store(ctxptr, code.idx, uintptr(slice.data)) } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '[', ']', '\n') code = code.end.next } @@ -300,7 +300,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opRootSliceHead: p := load(ctxptr, code.idx) if p == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -311,11 +311,11 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode store(ctxptr, code.idx, uintptr(slice.data)) if slice.len > 0 { b = append(b, '[', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) code = code.next store(ctxptr, code.idx, uintptr(slice.data)) } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '[', ']', ',', '\n') code = code.end.next } @@ -325,7 +325,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode length := load(ctxptr, code.length) idx++ if idx < length { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) data := load(ctxptr, code.headIdx) size := code.size @@ -334,7 +334,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } else { b = b[:len(b)-2] b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, ']', ',', '\n') code = code.end.next } @@ -343,33 +343,33 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode length := load(ctxptr, code.length) idx++ if idx < length { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) code = code.next data := load(ctxptr, code.headIdx) store(ctxptr, code.idx, data+idx*code.size) } else { b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, ']') code = code.end.next } case opArrayHead: p := load(ctxptr, code.idx) if p == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { if code.length > 0 { b = append(b, '[', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, 0) code = code.next store(ctxptr, code.idx, p) } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '[', ']', ',', '\n') code = code.end.next } @@ -378,7 +378,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode idx := load(ctxptr, code.elemIdx) idx++ if idx < code.length { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) p := load(ctxptr, code.headIdx) size := code.size @@ -387,14 +387,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } else { b = b[:len(b)-2] b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, ']', ',', '\n') code = code.end.next } case opMapHead: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -415,14 +415,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } else { - b = encodeIndent(ctx, b, code.next.indent) + b = appendIndent(ctx, b, code.next.indent) } key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) code = code.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next } @@ -430,7 +430,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opMapHeadLoad: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) code = code.end.next } else { @@ -438,7 +438,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr = ptrToPtr(ptr) uptr := ptrToUnsafePtr(ptr) if uintptr(uptr) == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -461,12 +461,12 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } else { - b = encodeIndent(ctx, b, code.next.indent) + b = appendIndent(ctx, b, code.next.indent) } code = code.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next } @@ -477,7 +477,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode idx++ if (opt & EncodeOptionUnorderedMap) != 0 { if idx < length { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) store(ctxptr, code.elemIdx, idx) ptr := load(ctxptr, code.mapIter) iter := ptrToUnsafePtr(ptr) @@ -487,7 +487,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } else { last := len(b) - 1 b[last] = '\n' - b = encodeIndent(ctx, b, code.indent-1) + b = appendIndent(ctx, b, code.indent-1) b = append(b, '}', ',', '\n') code = code.end.next } @@ -573,20 +573,20 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHead: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else if code.next == code.end { // not exists fields - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next store(ctxptr, code.idx, ptr) } else { b = append(b, '{', '\n') if !code.anonymousKey { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') } @@ -603,18 +603,18 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') p := ptr + code.offset if p == 0 || *(*uintptr)(*(*unsafe.Pointer)(unsafe.Pointer(&p))) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next @@ -625,7 +625,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.idx) b = append(b, '{', '\n') if !code.anonymousKey { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') } @@ -636,7 +636,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.idx) b = append(b, '{', '\n') if !code.anonymousKey && ptr != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset @@ -656,7 +656,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -681,7 +681,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -703,7 +703,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -714,7 +714,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadIntOnly, opStructFieldHeadIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p))) @@ -725,7 +725,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := int64(ptrToInt(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -735,7 +735,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagIntOnly, opStructFieldHeadStringTagIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt(p))) @@ -754,7 +754,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -779,7 +779,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p))) @@ -799,7 +799,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -826,7 +826,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -850,7 +850,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p+code.offset))) @@ -870,7 +870,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -888,7 +888,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -913,7 +913,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -932,7 +932,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -948,7 +948,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -962,7 +962,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -978,7 +978,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -991,7 +991,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -1009,7 +1009,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1033,7 +1033,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p))) @@ -1049,7 +1049,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1072,7 +1072,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadIntPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -1095,7 +1095,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p+code.offset))) @@ -1112,7 +1112,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -1135,7 +1135,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(ptr))) @@ -1160,7 +1160,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1182,7 +1182,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -1193,7 +1193,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadInt8Only, opStructFieldHeadInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p))) @@ -1204,7 +1204,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := int64(ptrToInt8(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -1214,7 +1214,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt8Only, opStructFieldHeadStringTagInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt8(p))) @@ -1233,7 +1233,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1258,7 +1258,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p))) @@ -1278,7 +1278,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1305,7 +1305,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -1329,7 +1329,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p+code.offset))) @@ -1349,7 +1349,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -1367,7 +1367,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -1392,7 +1392,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -1411,7 +1411,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1427,7 +1427,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -1441,7 +1441,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -1457,7 +1457,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1470,7 +1470,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -1488,7 +1488,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1512,7 +1512,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p))) @@ -1528,7 +1528,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1551,7 +1551,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadInt8PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -1574,7 +1574,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p+code.offset))) @@ -1591,7 +1591,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -1614,7 +1614,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(ptr))) @@ -1639,7 +1639,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1661,7 +1661,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -1672,7 +1672,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadInt16Only, opStructFieldHeadInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p))) @@ -1683,7 +1683,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := int64(ptrToInt16(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -1693,7 +1693,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt16Only, opStructFieldHeadStringTagInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt16(p))) @@ -1712,7 +1712,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1737,7 +1737,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p))) @@ -1757,7 +1757,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1784,7 +1784,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -1808,7 +1808,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p+code.offset))) @@ -1828,7 +1828,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -1846,7 +1846,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -1871,7 +1871,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -1890,7 +1890,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1906,7 +1906,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -1920,7 +1920,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -1936,7 +1936,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1949,7 +1949,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -1967,7 +1967,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -1991,7 +1991,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p))) @@ -2007,7 +2007,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2030,7 +2030,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadInt16PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -2053,7 +2053,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p+code.offset))) @@ -2070,7 +2070,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -2093,7 +2093,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(ptr))) @@ -2118,7 +2118,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2140,7 +2140,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -2151,7 +2151,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadInt32Only, opStructFieldHeadInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p))) @@ -2162,7 +2162,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := int64(ptrToInt32(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2172,7 +2172,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt32Only, opStructFieldHeadStringTagInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt32(p))) @@ -2191,7 +2191,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2216,7 +2216,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p))) @@ -2236,7 +2236,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2263,7 +2263,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -2287,7 +2287,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p+code.offset))) @@ -2307,7 +2307,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -2325,7 +2325,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -2350,7 +2350,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -2369,7 +2369,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2385,7 +2385,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -2399,7 +2399,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -2415,7 +2415,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2428,7 +2428,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -2446,7 +2446,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2470,7 +2470,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p))) @@ -2486,7 +2486,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2509,7 +2509,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadInt32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -2532,7 +2532,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p+code.offset))) @@ -2549,7 +2549,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -2572,7 +2572,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(ptr)) @@ -2597,7 +2597,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2619,7 +2619,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -2630,7 +2630,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadInt64Only, opStructFieldHeadInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p)) @@ -2641,7 +2641,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := ptrToInt64(p) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2651,7 +2651,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagInt64Only, opStructFieldHeadStringTagInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, ptrToInt64(p)) @@ -2670,7 +2670,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2695,7 +2695,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p)) @@ -2715,7 +2715,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2742,7 +2742,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -2766,7 +2766,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p+code.offset)) @@ -2786,7 +2786,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -2804,7 +2804,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -2829,7 +2829,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -2848,7 +2848,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2864,7 +2864,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -2878,7 +2878,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -2894,7 +2894,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -2907,7 +2907,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -2925,7 +2925,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2949,7 +2949,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p)) @@ -2965,7 +2965,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -2988,7 +2988,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadInt64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3011,7 +3011,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p+code.offset)) @@ -3028,7 +3028,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3051,7 +3051,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -3076,7 +3076,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3098,7 +3098,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -3109,7 +3109,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUintOnly, opStructFieldHeadUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p))) @@ -3120,7 +3120,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := uint64(ptrToUint(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -3130,7 +3130,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUintOnly, opStructFieldHeadStringTagUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint(p))) @@ -3149,7 +3149,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -3174,7 +3174,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p))) @@ -3194,7 +3194,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -3221,7 +3221,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3245,7 +3245,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p+code.offset))) @@ -3265,7 +3265,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3283,7 +3283,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -3308,7 +3308,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -3327,7 +3327,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3343,7 +3343,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -3357,7 +3357,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -3373,7 +3373,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3386,7 +3386,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -3404,7 +3404,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -3428,7 +3428,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p))) @@ -3444,7 +3444,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -3467,7 +3467,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadUintPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3490,7 +3490,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p+code.offset))) @@ -3507,7 +3507,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3530,7 +3530,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(ptr))) @@ -3555,7 +3555,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3577,7 +3577,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -3588,7 +3588,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUint8Only, opStructFieldHeadUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p))) @@ -3599,7 +3599,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := uint64(ptrToUint8(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -3609,7 +3609,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint8Only, opStructFieldHeadStringTagUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint8(p))) @@ -3628,7 +3628,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -3653,7 +3653,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p))) @@ -3673,7 +3673,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -3700,7 +3700,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3724,7 +3724,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p+code.offset))) @@ -3744,7 +3744,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3762,7 +3762,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -3787,7 +3787,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -3806,7 +3806,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3822,7 +3822,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -3836,7 +3836,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -3852,7 +3852,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3865,7 +3865,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -3883,7 +3883,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -3907,7 +3907,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p))) @@ -3923,7 +3923,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -3946,7 +3946,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadUint8PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -3969,7 +3969,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p+code.offset))) @@ -3986,7 +3986,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4009,7 +4009,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(ptr))) @@ -4034,7 +4034,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4056,7 +4056,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -4067,7 +4067,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUint16Only, opStructFieldHeadUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p))) @@ -4078,7 +4078,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := uint64(ptrToUint16(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -4088,7 +4088,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint16Only, opStructFieldHeadStringTagUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint16(p))) @@ -4107,7 +4107,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -4132,7 +4132,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p))) @@ -4152,7 +4152,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -4179,7 +4179,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4203,7 +4203,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p+code.offset))) @@ -4223,7 +4223,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4241,7 +4241,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -4266,7 +4266,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -4285,7 +4285,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4301,7 +4301,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -4315,7 +4315,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -4331,7 +4331,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4344,7 +4344,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -4362,7 +4362,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -4386,7 +4386,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p))) @@ -4402,7 +4402,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -4425,7 +4425,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadUint16PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4448,7 +4448,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p+code.offset))) @@ -4465,7 +4465,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4488,7 +4488,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(ptr))) @@ -4513,7 +4513,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4535,7 +4535,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -4546,7 +4546,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUint32Only, opStructFieldHeadUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p))) @@ -4557,7 +4557,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := uint64(ptrToUint32(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -4567,7 +4567,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint32Only, opStructFieldHeadStringTagUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint32(p))) @@ -4586,7 +4586,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -4611,7 +4611,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p))) @@ -4631,7 +4631,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -4658,7 +4658,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4682,7 +4682,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p+code.offset))) @@ -4702,7 +4702,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4720,7 +4720,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -4745,7 +4745,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -4764,7 +4764,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4780,7 +4780,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -4794,7 +4794,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -4810,7 +4810,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4823,7 +4823,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -4841,7 +4841,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -4865,7 +4865,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p))) @@ -4881,7 +4881,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -4904,7 +4904,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadUint32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4927,7 +4927,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p+code.offset))) @@ -4944,7 +4944,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -4967,7 +4967,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(ptr)) @@ -4992,7 +4992,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -5014,7 +5014,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -5025,7 +5025,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadUint64Only, opStructFieldHeadUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p)) @@ -5036,7 +5036,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := ptrToUint64(p) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -5046,7 +5046,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagUint64Only, opStructFieldHeadStringTagUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, ptrToUint64(p)) @@ -5065,7 +5065,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -5090,7 +5090,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p)) @@ -5110,7 +5110,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -5137,7 +5137,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -5161,7 +5161,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p+code.offset)) @@ -5181,7 +5181,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -5199,7 +5199,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -5224,7 +5224,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -5243,7 +5243,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -5259,7 +5259,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -5273,7 +5273,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -5289,7 +5289,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -5302,7 +5302,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -5320,7 +5320,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -5344,7 +5344,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p)) @@ -5360,7 +5360,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -5383,7 +5383,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadUint64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -5406,7 +5406,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p+code.offset)) @@ -5423,7 +5423,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -5446,7 +5446,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(ptr)) @@ -5471,7 +5471,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5493,7 +5493,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) @@ -5504,7 +5504,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadFloat32Only, opStructFieldHeadFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p)) @@ -5515,7 +5515,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := ptrToFloat32(p) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5525,7 +5525,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagFloat32Only, opStructFieldHeadStringTagFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeFloat32(b, ptrToFloat32(p)) @@ -5544,7 +5544,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -5569,7 +5569,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p)) @@ -5589,7 +5589,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -5616,7 +5616,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -5640,7 +5640,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p+code.offset)) @@ -5660,7 +5660,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -5678,7 +5678,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -5703,7 +5703,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(ptr)) @@ -5722,7 +5722,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5738,7 +5738,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -5752,7 +5752,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(ptr)) @@ -5768,7 +5768,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5781,7 +5781,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -5799,7 +5799,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -5823,7 +5823,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p)) @@ -5839,7 +5839,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -5862,7 +5862,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadFloat32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -5885,7 +5885,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p+code.offset)) @@ -5902,7 +5902,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -5929,7 +5929,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode return nil, errUnsupportedFloat(v) } b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -5957,7 +5957,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -5979,7 +5979,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') v := ptrToFloat64(ptr + code.offset) @@ -5994,7 +5994,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadFloat64Only, opStructFieldHeadFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6012,7 +6012,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode return nil, errUnsupportedFloat(v) } if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -6022,7 +6022,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagFloat64Only, opStructFieldHeadStringTagFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') v := ptrToFloat64(p) @@ -6045,7 +6045,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -6074,7 +6074,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6098,7 +6098,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -6129,7 +6129,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -6157,7 +6157,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6181,7 +6181,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -6203,7 +6203,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -6232,7 +6232,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(ptr) @@ -6258,7 +6258,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -6274,7 +6274,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -6292,7 +6292,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(ptr) @@ -6312,7 +6312,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(ptr) @@ -6329,7 +6329,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = append(b, '"') @@ -6351,7 +6351,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -6379,7 +6379,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6399,7 +6399,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -6426,7 +6426,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadFloat64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -6453,7 +6453,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6474,7 +6474,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -6501,7 +6501,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(ptr)) @@ -6526,7 +6526,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == "" { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -6548,7 +6548,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToString(ptr + code.offset) @@ -6559,7 +6559,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringOnly, opStructFieldHeadStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(p)) @@ -6570,7 +6570,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') v := ptrToString(p) if v != "" { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -6580,7 +6580,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldPtrHeadStringTagStringOnly, opStructFieldHeadStringTagStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(p)))) @@ -6598,7 +6598,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -6623,7 +6623,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(p)) @@ -6643,7 +6643,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -6668,7 +6668,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -6692,7 +6692,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(p+code.offset)) @@ -6712,7 +6712,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -6728,7 +6728,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -6753,7 +6753,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(ptr+code.offset)) @@ -6772,7 +6772,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == "" { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -6788,7 +6788,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(ptr+code.offset)))) @@ -6800,7 +6800,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(ptr+code.offset)) @@ -6816,7 +6816,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if v == "" { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -6829,7 +6829,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, string(encodeEscapedString([]byte{}, ptrToString(ptr+code.offset)))) @@ -6845,7 +6845,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -6869,7 +6869,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(p)) @@ -6885,7 +6885,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p = ptrToPtr(p) @@ -6906,7 +6906,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -6929,7 +6929,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(p+code.offset)) @@ -6946,7 +6946,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode fallthrough case opStructFieldAnonymousHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -6962,14 +6962,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeBool(b, ptrToBool(ptr)) @@ -6982,14 +6982,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, ptrToBytes(ptr)) @@ -7005,18 +7005,18 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') v := ptrToBool(ptr + code.offset) if !v { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeBool(b, v) @@ -7033,18 +7033,18 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') v := ptrToBytes(ptr + code.offset) if len(v) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -7067,7 +7067,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } else { b = append(b, '{', '\n') p := ptr + code.offset - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next @@ -7082,13 +7082,13 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeBool(b, ptrToBool(ptr+code.offset)) @@ -7105,13 +7105,13 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) @@ -7119,7 +7119,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next } case opStructField: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7132,7 +7132,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 || **(**uintptr)(unsafe.Pointer(&p)) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next @@ -7141,13 +7141,13 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldStringTag: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next store(ctxptr, code.idx, p) case opStructFieldInt: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7158,7 +7158,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7167,7 +7167,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -7175,7 +7175,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldInt8: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7186,7 +7186,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt8(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7195,7 +7195,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt8: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -7203,7 +7203,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldInt16: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7214,7 +7214,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt16(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7223,7 +7223,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt16: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -7231,7 +7231,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldInt32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7242,7 +7242,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7251,7 +7251,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -7259,7 +7259,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldInt64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7270,7 +7270,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -7279,7 +7279,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagInt64: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -7287,7 +7287,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldUint: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7298,7 +7298,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7307,7 +7307,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -7315,7 +7315,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldUint8: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7326,7 +7326,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint8(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7335,7 +7335,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint8: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -7343,7 +7343,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldUint16: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7354,7 +7354,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint16(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7363,7 +7363,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint16: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -7371,7 +7371,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldUint32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7382,7 +7382,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7391,7 +7391,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -7399,7 +7399,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldUint64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7410,7 +7410,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -7419,7 +7419,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagUint64: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -7427,7 +7427,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldFloat32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7438,7 +7438,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToFloat32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -7447,7 +7447,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagFloat32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) @@ -7455,7 +7455,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldFloat64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7473,7 +7473,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -7486,7 +7486,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeFloat64(b, v) @@ -7494,7 +7494,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldString: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7505,7 +7505,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToString(ptr + code.offset) if v != "" { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -7514,7 +7514,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagString: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') s := ptrToString(ptr + code.offset) @@ -7522,7 +7522,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldStringPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7538,7 +7538,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(p)) @@ -7546,7 +7546,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode } code = code.next case opStructFieldStringTagStringPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7559,7 +7559,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldBool: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7570,7 +7570,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToBool(ptr + code.offset) if v { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeBool(b, v) @@ -7579,7 +7579,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagBool: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeBool(b, ptrToBool(ptr+code.offset)) @@ -7587,7 +7587,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldBytes: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7598,7 +7598,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToBytes(ptr + code.offset) if len(v) > 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -7607,14 +7607,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagBytes: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldMarshalJSON: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7642,7 +7642,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset @@ -7670,7 +7670,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructFieldStringTagMarshalText: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset @@ -7683,7 +7683,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = encodeIndentComma(b) code = code.next case opStructFieldArray: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7703,13 +7703,13 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 || uintptr(array.data) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next } case opStructFieldSlice: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7729,13 +7729,13 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 || uintptr(slice.data) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next } case opStructFieldMap: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7764,14 +7764,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if mlen == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next } } case opStructFieldMapLoad: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7799,7 +7799,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if mlen == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') code = code.next @@ -7808,7 +7808,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode case opStructFieldStruct: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if p == 0 { @@ -7831,7 +7831,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') headCode := code.next @@ -7859,12 +7859,12 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') b = encodeIndentComma(b) code = code.next case opStructEndInt: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7875,7 +7875,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7890,7 +7890,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -7898,7 +7898,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -7906,7 +7906,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndIntPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7922,7 +7922,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p))) @@ -7937,14 +7937,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagIntPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7959,7 +7959,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt8: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7970,7 +7970,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt8(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7985,7 +7985,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -7993,7 +7993,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt8: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -8001,7 +8001,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt8Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8017,7 +8017,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p))) @@ -8032,14 +8032,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt8Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8054,7 +8054,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt16: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8065,7 +8065,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt16(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -8080,7 +8080,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8088,7 +8088,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt16: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -8096,7 +8096,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt16Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8112,7 +8112,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p))) @@ -8127,14 +8127,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt16Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8149,7 +8149,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8160,7 +8160,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -8175,7 +8175,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8183,7 +8183,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -8191,7 +8191,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8207,7 +8207,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p))) @@ -8222,14 +8222,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8244,7 +8244,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8255,7 +8255,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToInt64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, v) @@ -8270,7 +8270,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8278,7 +8278,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagInt64: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -8286,7 +8286,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8302,7 +8302,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p)) @@ -8317,14 +8317,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8339,7 +8339,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8350,7 +8350,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -8365,7 +8365,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8373,7 +8373,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -8381,7 +8381,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUintPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8397,7 +8397,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p))) @@ -8412,14 +8412,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUintPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8434,7 +8434,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint8: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8445,7 +8445,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint8(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -8460,7 +8460,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8468,7 +8468,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint8: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -8476,7 +8476,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint8Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8492,7 +8492,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p))) @@ -8507,14 +8507,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint8Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8529,7 +8529,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint16: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8540,7 +8540,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint16(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -8555,7 +8555,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8563,7 +8563,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint16: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -8571,7 +8571,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint16Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8587,7 +8587,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p))) @@ -8602,14 +8602,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint16Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8624,7 +8624,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8635,7 +8635,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -8650,7 +8650,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8658,7 +8658,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -8666,7 +8666,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8682,7 +8682,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p))) @@ -8697,14 +8697,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8719,7 +8719,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8730,7 +8730,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToUint64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, v) @@ -8745,7 +8745,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8753,7 +8753,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagUint64: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -8761,7 +8761,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8777,7 +8777,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p)) @@ -8792,14 +8792,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8814,7 +8814,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8825,7 +8825,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToFloat32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -8840,7 +8840,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8848,7 +8848,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagFloat32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) @@ -8856,7 +8856,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8872,7 +8872,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p)) @@ -8887,14 +8887,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagFloat32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8909,7 +8909,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8924,7 +8924,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToFloat64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') if math.IsInf(v, 0) || math.IsNaN(v) { @@ -8942,7 +8942,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8954,7 +8954,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeFloat64(b, v) @@ -8962,7 +8962,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8982,7 +8982,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') v := ptrToFloat64(p) @@ -9001,14 +9001,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagFloat64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9027,7 +9027,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndString: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9038,7 +9038,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToString(ptr + code.offset) if v != "" { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, v) @@ -9053,7 +9053,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9061,7 +9061,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagString: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') s := ptrToString(ptr + code.offset) @@ -9069,7 +9069,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndStringPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9085,7 +9085,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeEscapedString(b, ptrToString(p)) @@ -9100,14 +9100,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagStringPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9120,7 +9120,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndBool: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9131,7 +9131,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToBool(ptr + code.offset) if v { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeBool(b, v) @@ -9146,7 +9146,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9154,7 +9154,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagBool: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ', '"') b = encodeBool(b, ptrToBool(ptr+code.offset)) @@ -9162,7 +9162,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndBytes: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9173,7 +9173,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode ptr := load(ctxptr, code.headIdx) v := ptrToBytes(ptr + code.offset) if len(v) > 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -9188,7 +9188,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9196,14 +9196,14 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagBytes: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndMarshalJSON: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9231,7 +9231,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset @@ -9258,7 +9258,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode code = code.next case opStructEndStringTagMarshalText: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.escapedKey...) b = append(b, ' ') p := ptr + code.offset diff --git a/encode_vm_indent.go b/encode_vm_indent.go index afcb21f..ff5c8d2 100644 --- a/encode_vm_indent.go +++ b/encode_vm_indent.go @@ -277,7 +277,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opSliceHead: p := load(ctxptr, code.idx) if p == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -288,11 +288,11 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op store(ctxptr, code.idx, uintptr(slice.data)) if slice.len > 0 { b = append(b, '[', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) code = code.next store(ctxptr, code.idx, uintptr(slice.data)) } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '[', ']', '\n') code = code.end.next } @@ -300,7 +300,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opRootSliceHead: p := load(ctxptr, code.idx) if p == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -311,11 +311,11 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op store(ctxptr, code.idx, uintptr(slice.data)) if slice.len > 0 { b = append(b, '[', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) code = code.next store(ctxptr, code.idx, uintptr(slice.data)) } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '[', ']', ',', '\n') code = code.end.next } @@ -325,7 +325,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op length := load(ctxptr, code.length) idx++ if idx < length { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) data := load(ctxptr, code.headIdx) size := code.size @@ -334,7 +334,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op } else { b = b[:len(b)-2] b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, ']', ',', '\n') code = code.end.next } @@ -343,33 +343,33 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op length := load(ctxptr, code.length) idx++ if idx < length { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) code = code.next data := load(ctxptr, code.headIdx) store(ctxptr, code.idx, data+idx*code.size) } else { b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, ']') code = code.end.next } case opArrayHead: p := load(ctxptr, code.idx) if p == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { if code.length > 0 { b = append(b, '[', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, 0) code = code.next store(ctxptr, code.idx, p) } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '[', ']', ',', '\n') code = code.end.next } @@ -378,7 +378,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op idx := load(ctxptr, code.elemIdx) idx++ if idx < code.length { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) store(ctxptr, code.elemIdx, idx) p := load(ctxptr, code.headIdx) size := code.size @@ -387,14 +387,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op } else { b = b[:len(b)-2] b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, ']', ',', '\n') code = code.end.next } case opMapHead: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -415,14 +415,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } else { - b = encodeIndent(ctx, b, code.next.indent) + b = appendIndent(ctx, b, code.next.indent) } key := mapiterkey(iter) store(ctxptr, code.next.idx, uintptr(key)) code = code.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next } @@ -430,7 +430,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opMapHeadLoad: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) code = code.end.next } else { @@ -438,7 +438,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr = ptrToPtr(ptr) uptr := ptrToUnsafePtr(ptr) if uintptr(uptr) == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next @@ -461,12 +461,12 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ctx.keepRefs = append(ctx.keepRefs, unsafe.Pointer(mapCtx)) store(ctxptr, code.end.mapPos, uintptr(unsafe.Pointer(mapCtx))) } else { - b = encodeIndent(ctx, b, code.next.indent) + b = appendIndent(ctx, b, code.next.indent) } code = code.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next } @@ -477,7 +477,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op idx++ if (opt & EncodeOptionUnorderedMap) != 0 { if idx < length { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) store(ctxptr, code.elemIdx, idx) ptr := load(ctxptr, code.mapIter) iter := ptrToUnsafePtr(ptr) @@ -487,7 +487,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op } else { last := len(b) - 1 b[last] = '\n' - b = encodeIndent(ctx, b, code.indent-1) + b = appendIndent(ctx, b, code.indent-1) b = append(b, '}', ',', '\n') code = code.end.next } @@ -573,20 +573,20 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHead: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else if code.next == code.end { // not exists fields - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '}', ',', '\n') code = code.end.next store(ctxptr, code.idx, ptr) } else { b = append(b, '{', '\n') if !code.anonymousKey { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') } @@ -603,18 +603,18 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadOmitEmpty: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') p := ptr + code.offset if p == 0 || *(*uintptr)(*(*unsafe.Pointer)(unsafe.Pointer(&p))) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') code = code.next @@ -625,7 +625,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.idx) b = append(b, '{', '\n') if !code.anonymousKey { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') } @@ -636,7 +636,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.idx) b = append(b, '{', '\n') if !code.anonymousKey && ptr != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset @@ -656,7 +656,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -681,7 +681,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -703,7 +703,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -714,7 +714,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadIntOnly, opStructFieldHeadIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p))) @@ -725,7 +725,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := int64(ptrToInt(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -735,7 +735,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagIntOnly, opStructFieldHeadStringTagIntOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt(p))) @@ -754,7 +754,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -779,7 +779,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p))) @@ -799,7 +799,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -826,7 +826,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -850,7 +850,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p+code.offset))) @@ -870,7 +870,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -888,7 +888,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -913,7 +913,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -932,7 +932,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -948,7 +948,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -962,7 +962,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -978,7 +978,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -991,7 +991,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -1009,7 +1009,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1033,7 +1033,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p))) @@ -1049,7 +1049,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1072,7 +1072,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadIntPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -1095,7 +1095,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p+code.offset))) @@ -1112,7 +1112,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagIntPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -1135,7 +1135,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(ptr))) @@ -1160,7 +1160,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1182,7 +1182,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -1193,7 +1193,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadInt8Only, opStructFieldHeadInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p))) @@ -1204,7 +1204,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := int64(ptrToInt8(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -1214,7 +1214,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagInt8Only, opStructFieldHeadStringTagInt8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt8(p))) @@ -1233,7 +1233,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1258,7 +1258,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p))) @@ -1278,7 +1278,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1305,7 +1305,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -1329,7 +1329,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p+code.offset))) @@ -1349,7 +1349,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -1367,7 +1367,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -1392,7 +1392,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -1411,7 +1411,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1427,7 +1427,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -1441,7 +1441,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -1457,7 +1457,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1470,7 +1470,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -1488,7 +1488,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1512,7 +1512,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p))) @@ -1528,7 +1528,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1551,7 +1551,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadInt8PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -1574,7 +1574,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p+code.offset))) @@ -1591,7 +1591,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagInt8PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -1614,7 +1614,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(ptr))) @@ -1639,7 +1639,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1661,7 +1661,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -1672,7 +1672,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadInt16Only, opStructFieldHeadInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p))) @@ -1683,7 +1683,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := int64(ptrToInt16(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -1693,7 +1693,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagInt16Only, opStructFieldHeadStringTagInt16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt16(p))) @@ -1712,7 +1712,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1737,7 +1737,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p))) @@ -1757,7 +1757,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1784,7 +1784,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -1808,7 +1808,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p+code.offset))) @@ -1828,7 +1828,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -1846,7 +1846,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -1871,7 +1871,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -1890,7 +1890,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1906,7 +1906,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -1920,7 +1920,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -1936,7 +1936,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -1949,7 +1949,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -1967,7 +1967,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -1991,7 +1991,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p))) @@ -2007,7 +2007,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2030,7 +2030,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadInt16PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -2053,7 +2053,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p+code.offset))) @@ -2070,7 +2070,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagInt16PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -2093,7 +2093,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(ptr))) @@ -2118,7 +2118,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2140,7 +2140,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -2151,7 +2151,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadInt32Only, opStructFieldHeadInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p))) @@ -2162,7 +2162,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := int64(ptrToInt32(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2172,7 +2172,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagInt32Only, opStructFieldHeadStringTagInt32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt32(p))) @@ -2191,7 +2191,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2216,7 +2216,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p))) @@ -2236,7 +2236,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2263,7 +2263,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -2287,7 +2287,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p+code.offset))) @@ -2307,7 +2307,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -2325,7 +2325,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -2350,7 +2350,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -2369,7 +2369,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2385,7 +2385,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -2399,7 +2399,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -2415,7 +2415,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -2428,7 +2428,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -2446,7 +2446,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2470,7 +2470,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p))) @@ -2486,7 +2486,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2509,7 +2509,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadInt32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -2532,7 +2532,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p+code.offset))) @@ -2549,7 +2549,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagInt32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -2572,7 +2572,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(ptr)) @@ -2597,7 +2597,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2619,7 +2619,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -2630,7 +2630,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadInt64Only, opStructFieldHeadInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p)) @@ -2641,7 +2641,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := ptrToInt64(p) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2651,7 +2651,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagInt64Only, opStructFieldHeadStringTagInt64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, ptrToInt64(p)) @@ -2670,7 +2670,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2695,7 +2695,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p)) @@ -2715,7 +2715,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2742,7 +2742,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -2766,7 +2766,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p+code.offset)) @@ -2786,7 +2786,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -2804,7 +2804,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -2829,7 +2829,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -2848,7 +2848,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2864,7 +2864,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -2878,7 +2878,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -2894,7 +2894,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -2907,7 +2907,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -2925,7 +2925,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2949,7 +2949,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p)) @@ -2965,7 +2965,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -2988,7 +2988,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadInt64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3011,7 +3011,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p+code.offset)) @@ -3028,7 +3028,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagInt64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3051,7 +3051,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -3076,7 +3076,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3098,7 +3098,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -3109,7 +3109,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadUintOnly, opStructFieldHeadUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p))) @@ -3120,7 +3120,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := uint64(ptrToUint(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -3130,7 +3130,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagUintOnly, opStructFieldHeadStringTagUintOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint(p))) @@ -3149,7 +3149,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -3174,7 +3174,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p))) @@ -3194,7 +3194,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -3221,7 +3221,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3245,7 +3245,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p+code.offset))) @@ -3265,7 +3265,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3283,7 +3283,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -3308,7 +3308,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -3327,7 +3327,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3343,7 +3343,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -3357,7 +3357,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -3373,7 +3373,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3386,7 +3386,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -3404,7 +3404,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -3428,7 +3428,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p))) @@ -3444,7 +3444,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -3467,7 +3467,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadUintPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3490,7 +3490,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p+code.offset))) @@ -3507,7 +3507,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagUintPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3530,7 +3530,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(ptr))) @@ -3555,7 +3555,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3577,7 +3577,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -3588,7 +3588,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadUint8Only, opStructFieldHeadUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p))) @@ -3599,7 +3599,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := uint64(ptrToUint8(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -3609,7 +3609,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagUint8Only, opStructFieldHeadStringTagUint8Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint8(p))) @@ -3628,7 +3628,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -3653,7 +3653,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p))) @@ -3673,7 +3673,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -3700,7 +3700,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3724,7 +3724,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p+code.offset))) @@ -3744,7 +3744,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3762,7 +3762,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -3787,7 +3787,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -3806,7 +3806,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3822,7 +3822,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -3836,7 +3836,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -3852,7 +3852,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -3865,7 +3865,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -3883,7 +3883,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -3907,7 +3907,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p))) @@ -3923,7 +3923,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -3946,7 +3946,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadUint8PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -3969,7 +3969,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p+code.offset))) @@ -3986,7 +3986,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagUint8PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4009,7 +4009,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(ptr))) @@ -4034,7 +4034,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4056,7 +4056,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -4067,7 +4067,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadUint16Only, opStructFieldHeadUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p))) @@ -4078,7 +4078,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := uint64(ptrToUint16(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -4088,7 +4088,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagUint16Only, opStructFieldHeadStringTagUint16Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint16(p))) @@ -4107,7 +4107,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -4132,7 +4132,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p))) @@ -4152,7 +4152,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -4179,7 +4179,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4203,7 +4203,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p+code.offset))) @@ -4223,7 +4223,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4241,7 +4241,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -4266,7 +4266,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -4285,7 +4285,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4301,7 +4301,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -4315,7 +4315,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -4331,7 +4331,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4344,7 +4344,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -4362,7 +4362,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -4386,7 +4386,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p))) @@ -4402,7 +4402,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -4425,7 +4425,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadUint16PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4448,7 +4448,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p+code.offset))) @@ -4465,7 +4465,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagUint16PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4488,7 +4488,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(ptr))) @@ -4513,7 +4513,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4535,7 +4535,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -4546,7 +4546,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadUint32Only, opStructFieldHeadUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p))) @@ -4557,7 +4557,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := uint64(ptrToUint32(p)) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -4567,7 +4567,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagUint32Only, opStructFieldHeadStringTagUint32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint32(p))) @@ -4586,7 +4586,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -4611,7 +4611,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p))) @@ -4631,7 +4631,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -4658,7 +4658,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4682,7 +4682,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p+code.offset))) @@ -4702,7 +4702,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4720,7 +4720,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -4745,7 +4745,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -4764,7 +4764,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4780,7 +4780,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -4794,7 +4794,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -4810,7 +4810,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -4823,7 +4823,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -4841,7 +4841,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -4865,7 +4865,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p))) @@ -4881,7 +4881,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -4904,7 +4904,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadUint32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4927,7 +4927,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p+code.offset))) @@ -4944,7 +4944,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagUint32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -4967,7 +4967,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(ptr)) @@ -4992,7 +4992,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -5014,7 +5014,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -5025,7 +5025,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadUint64Only, opStructFieldHeadUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p)) @@ -5036,7 +5036,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := ptrToUint64(p) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -5046,7 +5046,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagUint64Only, opStructFieldHeadStringTagUint64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, ptrToUint64(p)) @@ -5065,7 +5065,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -5090,7 +5090,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p)) @@ -5110,7 +5110,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -5137,7 +5137,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -5161,7 +5161,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p+code.offset)) @@ -5181,7 +5181,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -5199,7 +5199,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -5224,7 +5224,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -5243,7 +5243,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -5259,7 +5259,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -5273,7 +5273,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -5289,7 +5289,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -5302,7 +5302,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -5320,7 +5320,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -5344,7 +5344,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p)) @@ -5360,7 +5360,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -5383,7 +5383,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadUint64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -5406,7 +5406,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p+code.offset)) @@ -5423,7 +5423,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagUint64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -5446,7 +5446,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(ptr)) @@ -5471,7 +5471,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5493,7 +5493,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) @@ -5504,7 +5504,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadFloat32Only, opStructFieldHeadFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p)) @@ -5515,7 +5515,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := ptrToFloat32(p) if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5525,7 +5525,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagFloat32Only, opStructFieldHeadStringTagFloat32Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeFloat32(b, ptrToFloat32(p)) @@ -5544,7 +5544,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -5569,7 +5569,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p)) @@ -5589,7 +5589,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -5616,7 +5616,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -5640,7 +5640,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p+code.offset)) @@ -5660,7 +5660,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -5678,7 +5678,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -5703,7 +5703,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(ptr)) @@ -5722,7 +5722,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5738,7 +5738,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -5752,7 +5752,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(ptr)) @@ -5768,7 +5768,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -5781,7 +5781,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -5799,7 +5799,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -5823,7 +5823,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p)) @@ -5839,7 +5839,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -5862,7 +5862,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadFloat32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -5885,7 +5885,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p+code.offset)) @@ -5902,7 +5902,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagFloat32PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -5929,7 +5929,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op return nil, errUnsupportedFloat(v) } b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -5957,7 +5957,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -5979,7 +5979,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') v := ptrToFloat64(ptr + code.offset) @@ -5994,7 +5994,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadFloat64Only, opStructFieldHeadFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6012,7 +6012,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op return nil, errUnsupportedFloat(v) } if v != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -6022,7 +6022,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagFloat64Only, opStructFieldHeadStringTagFloat64Only: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') v := ptrToFloat64(p) @@ -6045,7 +6045,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -6074,7 +6074,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6098,7 +6098,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -6129,7 +6129,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -6157,7 +6157,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6181,7 +6181,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -6203,7 +6203,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -6232,7 +6232,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(ptr) @@ -6258,7 +6258,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -6274,7 +6274,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -6292,7 +6292,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(ptr) @@ -6312,7 +6312,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(ptr) @@ -6329,7 +6329,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = append(b, '"') @@ -6351,7 +6351,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -6379,7 +6379,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6399,7 +6399,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -6426,7 +6426,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadFloat64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -6453,7 +6453,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(p) @@ -6474,7 +6474,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagFloat64PtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -6501,7 +6501,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(ptr)) @@ -6526,7 +6526,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == "" { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -6548,7 +6548,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') v := ptrToString(ptr + code.offset) @@ -6559,7 +6559,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringOnly, opStructFieldHeadStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(p)) @@ -6570,7 +6570,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') v := ptrToString(p) if v != "" { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -6580,7 +6580,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldPtrHeadStringTagStringOnly, opStructFieldHeadStringTagStringOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(p)))) @@ -6598,7 +6598,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -6623,7 +6623,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = append(b, '{', '\n') p = ptrToPtr(p) if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(p)) @@ -6643,7 +6643,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op break } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -6668,7 +6668,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -6692,7 +6692,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op p := load(ctxptr, code.idx) b = append(b, '{', '\n') if p != 0 { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(p+code.offset)) @@ -6712,7 +6712,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -6728,7 +6728,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeNull(b) } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') for i := 0; i < code.ptrNum; i++ { @@ -6753,7 +6753,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) @@ -6772,7 +6772,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == "" { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -6788,7 +6788,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(ptr+code.offset)))) @@ -6800,7 +6800,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(ptr+code.offset)) @@ -6816,7 +6816,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if v == "" { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -6829,7 +6829,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if ptr == 0 { code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, string(encodeNoEscapedString([]byte{}, ptrToString(ptr+code.offset)))) @@ -6845,7 +6845,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -6869,7 +6869,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(p)) @@ -6885,7 +6885,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.end.next break } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p = ptrToPtr(p) @@ -6906,7 +6906,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -6929,7 +6929,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(p+code.offset)) @@ -6946,7 +6946,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op fallthrough case opStructFieldAnonymousHeadStringTagStringPtrOnly: p := load(ctxptr, code.idx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -6962,14 +6962,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeBool(b, ptrToBool(ptr)) @@ -6982,14 +6982,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, ptrToBytes(ptr)) @@ -7005,18 +7005,18 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadOmitEmptyBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') v := ptrToBool(ptr + code.offset) if !v { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeBool(b, v) @@ -7033,18 +7033,18 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadOmitEmptyBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '{', '\n') v := ptrToBytes(ptr + code.offset) if len(v) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -7067,7 +7067,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op } else { b = append(b, '{', '\n') p := ptr + code.offset - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') code = code.next @@ -7082,13 +7082,13 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagBool: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeBool(b, ptrToBool(ptr+code.offset)) @@ -7105,13 +7105,13 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldHeadStringTagBytes: ptr := load(ctxptr, code.idx) if ptr == 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = encodeNull(b) b = encodeIndentComma(b) code = code.end.next } else { b = append(b, '{', '\n') - b = encodeIndent(ctx, b, code.indent+1) + b = appendIndent(ctx, b, code.indent+1) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) @@ -7119,7 +7119,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next } case opStructField: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7132,7 +7132,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 || **(**uintptr)(unsafe.Pointer(&p)) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next @@ -7141,13 +7141,13 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldStringTag: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next store(ctxptr, code.idx, p) case opStructFieldInt: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7158,7 +7158,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7167,7 +7167,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagInt: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -7175,7 +7175,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldInt8: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7186,7 +7186,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt8(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7195,7 +7195,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagInt8: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -7203,7 +7203,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldInt16: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7214,7 +7214,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt16(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7223,7 +7223,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagInt16: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -7231,7 +7231,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldInt32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7242,7 +7242,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7251,7 +7251,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagInt32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -7259,7 +7259,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldInt64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7270,7 +7270,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -7279,7 +7279,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagInt64: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -7287,7 +7287,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldUint: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7298,7 +7298,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7307,7 +7307,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagUint: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -7315,7 +7315,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldUint8: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7326,7 +7326,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint8(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7335,7 +7335,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagUint8: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -7343,7 +7343,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldUint16: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7354,7 +7354,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint16(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7363,7 +7363,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagUint16: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -7371,7 +7371,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldUint32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7382,7 +7382,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -7391,7 +7391,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagUint32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -7399,7 +7399,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldUint64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7410,7 +7410,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -7419,7 +7419,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagUint64: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -7427,7 +7427,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldFloat32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7438,7 +7438,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToFloat32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -7447,7 +7447,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagFloat32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) @@ -7455,7 +7455,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldFloat64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7473,7 +7473,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat64(b, v) @@ -7486,7 +7486,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeFloat64(b, v) @@ -7494,7 +7494,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldString: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7505,7 +7505,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToString(ptr + code.offset) if v != "" { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -7514,7 +7514,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagString: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') s := ptrToString(ptr + code.offset) @@ -7522,7 +7522,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldStringPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7538,7 +7538,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(p)) @@ -7546,7 +7546,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op } code = code.next case opStructFieldStringTagStringPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7559,7 +7559,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldBool: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7570,7 +7570,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToBool(ptr + code.offset) if v { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeBool(b, v) @@ -7579,7 +7579,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagBool: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeBool(b, ptrToBool(ptr+code.offset)) @@ -7587,7 +7587,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldBytes: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7598,7 +7598,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToBytes(ptr + code.offset) if len(v) > 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -7607,14 +7607,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagBytes: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = encodeIndentComma(b) code = code.next case opStructFieldMarshalJSON: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7642,7 +7642,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset @@ -7669,7 +7669,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructFieldStringTagMarshalText: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset @@ -7682,7 +7682,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = encodeIndentComma(b) code = code.next case opStructFieldArray: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7702,13 +7702,13 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 || uintptr(array.data) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next } case opStructFieldSlice: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7728,13 +7728,13 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 || uintptr(slice.data) == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next } case opStructFieldMap: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7763,14 +7763,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if mlen == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next } } case opStructFieldMapLoad: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7798,7 +7798,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if mlen == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') code = code.next @@ -7807,7 +7807,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op case opStructFieldStruct: ptr := load(ctxptr, code.headIdx) p := ptr + code.offset - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if p == 0 { @@ -7830,7 +7830,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if p == 0 { code = code.nextField } else { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') headCode := code.next @@ -7858,12 +7858,12 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') b = encodeIndentComma(b) code = code.next case opStructEndInt: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7874,7 +7874,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7889,7 +7889,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -7897,7 +7897,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagInt: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt(ptr+code.offset))) @@ -7905,7 +7905,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndIntPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7921,7 +7921,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt(p))) @@ -7936,14 +7936,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagIntPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7958,7 +7958,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt8: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -7969,7 +7969,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt8(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -7984,7 +7984,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -7992,7 +7992,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagInt8: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt8(ptr+code.offset))) @@ -8000,7 +8000,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt8Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8016,7 +8016,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt8(p))) @@ -8031,14 +8031,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt8Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8053,7 +8053,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt16: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8064,7 +8064,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt16(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -8079,7 +8079,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8087,7 +8087,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagInt16: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt16(ptr+code.offset))) @@ -8095,7 +8095,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt16Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8111,7 +8111,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt16(p))) @@ -8126,14 +8126,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt16Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8148,7 +8148,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8159,7 +8159,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(v)) @@ -8174,7 +8174,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8182,7 +8182,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagInt32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, int64(ptrToInt32(ptr+code.offset))) @@ -8190,7 +8190,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8206,7 +8206,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, int64(ptrToInt32(p))) @@ -8221,14 +8221,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8243,7 +8243,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8254,7 +8254,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToInt64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, v) @@ -8269,7 +8269,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8277,7 +8277,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagInt64: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendInt(b, ptrToInt64(ptr+code.offset)) @@ -8285,7 +8285,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndInt64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8301,7 +8301,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendInt(b, ptrToInt64(p)) @@ -8316,14 +8316,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagInt64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8338,7 +8338,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8349,7 +8349,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -8364,7 +8364,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8372,7 +8372,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagUint: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint(ptr+code.offset))) @@ -8380,7 +8380,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUintPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8396,7 +8396,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint(p))) @@ -8411,14 +8411,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUintPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8433,7 +8433,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint8: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8444,7 +8444,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint8(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -8459,7 +8459,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8467,7 +8467,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagUint8: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint8(ptr+code.offset))) @@ -8475,7 +8475,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint8Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8491,7 +8491,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint8(p))) @@ -8506,14 +8506,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint8Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8528,7 +8528,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint16: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8539,7 +8539,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint16(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -8554,7 +8554,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8562,7 +8562,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagUint16: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint16(ptr+code.offset))) @@ -8570,7 +8570,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint16Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8586,7 +8586,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint16(p))) @@ -8601,14 +8601,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint16Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8623,7 +8623,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8634,7 +8634,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(v)) @@ -8649,7 +8649,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8657,7 +8657,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagUint32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, uint64(ptrToUint32(ptr+code.offset))) @@ -8665,7 +8665,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8681,7 +8681,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, uint64(ptrToUint32(p))) @@ -8696,14 +8696,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8718,7 +8718,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8729,7 +8729,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToUint64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, v) @@ -8744,7 +8744,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8752,7 +8752,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagUint64: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = appendUint(b, ptrToUint64(ptr+code.offset)) @@ -8760,7 +8760,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndUint64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8776,7 +8776,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = appendUint(b, ptrToUint64(p)) @@ -8791,14 +8791,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagUint64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8813,7 +8813,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat32: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8824,7 +8824,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToFloat32(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, v) @@ -8839,7 +8839,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8847,7 +8847,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagFloat32: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeFloat32(b, ptrToFloat32(ptr+code.offset)) @@ -8855,7 +8855,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8871,7 +8871,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeFloat32(b, ptrToFloat32(p)) @@ -8886,14 +8886,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagFloat32Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8908,7 +8908,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat64: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8923,7 +8923,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToFloat64(ptr + code.offset) if v != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') if math.IsInf(v, 0) || math.IsNaN(v) { @@ -8941,7 +8941,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -8953,7 +8953,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op if math.IsInf(v, 0) || math.IsNaN(v) { return nil, errUnsupportedFloat(v) } - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeFloat64(b, v) @@ -8961,7 +8961,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndFloat64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -8981,7 +8981,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') v := ptrToFloat64(p) @@ -9000,14 +9000,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagFloat64Ptr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9026,7 +9026,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndString: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9037,7 +9037,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToString(ptr + code.offset) if v != "" { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, v) @@ -9052,7 +9052,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9060,7 +9060,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagString: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') s := ptrToString(ptr + code.offset) @@ -9068,7 +9068,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndStringPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9084,7 +9084,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) p := ptrToPtr(ptr + code.offset) if p != 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeNoEscapedString(b, ptrToString(p)) @@ -9099,14 +9099,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) } code = code.next case opStructEndStringTagStringPtr: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9119,7 +9119,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndBool: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9130,7 +9130,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToBool(ptr + code.offset) if v { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeBool(b, v) @@ -9145,7 +9145,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9153,7 +9153,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagBool: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ', '"') b = encodeBool(b, ptrToBool(ptr+code.offset)) @@ -9161,7 +9161,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndBytes: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9172,7 +9172,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op ptr := load(ctxptr, code.headIdx) v := ptrToBytes(ptr + code.offset) if len(v) > 0 { - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, v) @@ -9187,7 +9187,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op b = b[:len(b)-2] } b = append(b, '\n') - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, '}') } b = encodeIndentComma(b) @@ -9195,14 +9195,14 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagBytes: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') b = encodeByteSlice(b, ptrToBytes(ptr+code.offset)) b = appendStructEndIndent(ctx, b, code.indent-1) code = code.next case opStructEndMarshalJSON: - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') ptr := load(ctxptr, code.headIdx) @@ -9230,7 +9230,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagMarshalJSON: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset @@ -9257,7 +9257,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op code = code.next case opStructEndStringTagMarshalText: ptr := load(ctxptr, code.headIdx) - b = encodeIndent(ctx, b, code.indent) + b = appendIndent(ctx, b, code.indent) b = append(b, code.key...) b = append(b, ' ') p := ptr + code.offset From 04da39a443d87164a2b094e1162600cdd672e08d Mon Sep 17 00:00:00 2001 From: Masaaki Goshima Date: Mon, 1 Feb 2021 12:01:56 +0900 Subject: [PATCH 5/6] Fix error message --- encode_vm.go | 2 +- encode_vm_escaped.go | 2 +- encode_vm_escaped_indent.go | 2 +- encode_vm_indent.go | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/encode_vm.go b/encode_vm.go index 8690f07..f84e812 100644 --- a/encode_vm.go +++ b/encode_vm.go @@ -88,7 +88,7 @@ func encodeRun(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, opt Enco for { switch code.op { default: - return nil, fmt.Errorf("failed to handle opcode. doesn't implement %s", code.op) + return nil, fmt.Errorf("encoder: opcode %s has not been implemented", code.op) case opPtr: ptr := load(ctxptr, code.idx) code = code.next diff --git a/encode_vm_escaped.go b/encode_vm_escaped.go index 2d3e51a..7bc194f 100644 --- a/encode_vm_escaped.go +++ b/encode_vm_escaped.go @@ -21,7 +21,7 @@ func encodeRunEscaped(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, o for { switch code.op { default: - return nil, fmt.Errorf("failed to handle opcode. doesn't implement %s", code.op) + return nil, fmt.Errorf("encoder (escaped): opcode %s has not been implemented", code.op) case opPtr: ptr := load(ctxptr, code.idx) code = code.next diff --git a/encode_vm_escaped_indent.go b/encode_vm_escaped_indent.go index 26b2b22..c8804a1 100644 --- a/encode_vm_escaped_indent.go +++ b/encode_vm_escaped_indent.go @@ -20,7 +20,7 @@ func encodeRunEscapedIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcode for { switch code.op { default: - return nil, fmt.Errorf("failed to handle opcode. doesn't implement %s", code.op) + return nil, fmt.Errorf("encoder (escaped+indent): opcode %s has not been implemented", code.op) case opPtr: ptr := load(ctxptr, code.idx) code = code.next diff --git a/encode_vm_indent.go b/encode_vm_indent.go index ff5c8d2..587e328 100644 --- a/encode_vm_indent.go +++ b/encode_vm_indent.go @@ -20,7 +20,7 @@ func encodeRunIndent(ctx *encodeRuntimeContext, b []byte, codeSet *opcodeSet, op for { switch code.op { default: - return nil, fmt.Errorf("failed to handle opcode. doesn't implement %s", code.op) + return nil, fmt.Errorf("encoder (indent): opcode %s has not been implemented", code.op) case opPtr: ptr := load(ctxptr, code.idx) code = code.next From 1d9162789061bc2129fe42ed9baff3e0423e33a2 Mon Sep 17 00:00:00 2001 From: Masaaki Goshima Date: Mon, 1 Feb 2021 12:05:28 +0900 Subject: [PATCH 6/6] Add codecov.yml --- .codecov.yml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .codecov.yml diff --git a/.codecov.yml b/.codecov.yml new file mode 100644 index 0000000..555e91b --- /dev/null +++ b/.codecov.yml @@ -0,0 +1,28 @@ +codecov: + require_ci_to_pass: yes + +coverage: + precision: 2 + round: down + range: "70...100" + + status: + project: + default: + target: 70% + threshold: 2% + patch: off + changes: no + +parsers: + gcov: + branch_detection: + conditional: yes + loop: yes + method: no + macro: no + +comment: + layout: "header,diff" + behavior: default + require_changes: no