mirror of
https://github.com/google/go-jsonnet.git
synced 2025-09-29 09:21:03 +02:00
Fix local bind body not being desugared
In Go `for i, val := range arr` creates a *copy* so it was changing some temporary value.
This commit is contained in:
parent
f81573cb4e
commit
fd77883a3f
@ -302,8 +302,8 @@ func desugar(astPtr *astNode, objLevel int) (err error) {
|
||||
return unimplErr
|
||||
|
||||
case *astLocal:
|
||||
for _, bind := range ast.binds {
|
||||
err = desugar(&bind.body, objLevel)
|
||||
for i := range ast.binds {
|
||||
err = desugar(&ast.binds[i].body, objLevel)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user