Fix indent num contains recursive type

This commit is contained in:
Masaaki Goshima 2021-06-12 22:01:45 +09:00
parent a2ba5e8bcc
commit 79ccab759f
5 changed files with 5 additions and 5 deletions

View File

@ -484,7 +484,7 @@ func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]b
oldOffset := ptrOffset
ptrOffset += code.Jmp.CurLen * uintptrSize
oldBaseIndent := ctx.BaseIndent
ctx.BaseIndent += code.Indent - 1
ctx.BaseIndent += code.Indent
newLen := offsetNum + code.Jmp.CurLen + code.Jmp.NextLen
if curlen < newLen {

View File

@ -484,7 +484,7 @@ func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]b
oldOffset := ptrOffset
ptrOffset += code.Jmp.CurLen * uintptrSize
oldBaseIndent := ctx.BaseIndent
ctx.BaseIndent += code.Indent - 1
ctx.BaseIndent += code.Indent
newLen := offsetNum + code.Jmp.CurLen + code.Jmp.NextLen
if curlen < newLen {

View File

@ -484,7 +484,7 @@ func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]b
oldOffset := ptrOffset
ptrOffset += code.Jmp.CurLen * uintptrSize
oldBaseIndent := ctx.BaseIndent
ctx.BaseIndent += code.Indent - 1
ctx.BaseIndent += code.Indent
newLen := offsetNum + code.Jmp.CurLen + code.Jmp.NextLen
if curlen < newLen {

View File

@ -484,7 +484,7 @@ func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]b
oldOffset := ptrOffset
ptrOffset += code.Jmp.CurLen * uintptrSize
oldBaseIndent := ctx.BaseIndent
ctx.BaseIndent += code.Indent - 1
ctx.BaseIndent += code.Indent
newLen := offsetNum + code.Jmp.CurLen + code.Jmp.NextLen
if curlen < newLen {

View File

@ -484,7 +484,7 @@ func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]b
oldOffset := ptrOffset
ptrOffset += code.Jmp.CurLen * uintptrSize
oldBaseIndent := ctx.BaseIndent
ctx.BaseIndent += code.Indent - 1
ctx.BaseIndent += code.Indent
newLen := offsetNum + code.Jmp.CurLen + code.Jmp.NextLen
if curlen < newLen {