Remove unused condition

This commit is contained in:
Masaaki Goshima 2020-09-15 20:48:32 +09:00
parent e9e9aa8874
commit 6cac23acc3
1 changed files with 0 additions and 6 deletions

View File

@ -665,12 +665,6 @@ func (e *Encoder) run(ctx *encodeRuntimeContext, code *opcode) error {
case opStructFieldRecursiveEnd: case opStructFieldRecursiveEnd:
recursiveLevel-- recursiveLevel--
// Since the pointer addresses of root code and code.jmp.code may be common,
// `opStructFieldRecursive` processing may replace `opEnd` of root code with `opRecursiveEnd`.
// At that time, `recursiveLevel` becomes -1, so return here as normal processing.
if recursiveLevel < 0 {
return nil
}
// restore ctxptr // restore ctxptr
offset := load(ctxptr, code.idx) offset := load(ctxptr, code.idx)
code = (*opcode)(unsafe.Pointer(load(ctxptr, code.elemIdx))) code = (*opcode)(unsafe.Pointer(load(ctxptr, code.elemIdx)))