node: fix issue with lvalue err ordering
This commit is contained in:
parent
760d1ddbbd
commit
51ca4ecd77
2
node.go
2
node.go
@ -1280,7 +1280,7 @@ func (this *conversionState) convertAssignment(n *assign.Assign, isTopLevelState
|
||||
// we need to propagate errors
|
||||
switch n.Expression.(type) {
|
||||
case *expr.FunctionCall, *expr.StaticCall, *expr.New:
|
||||
ret := "_, " + lvalue + " = " + rvalue + "\n"
|
||||
ret := lvalue + ", err = " + rvalue + "\n"
|
||||
ret += "if err != nil {\n"
|
||||
ret += this.currentErrHandler
|
||||
ret += "}\n"
|
||||
|
Loading…
Reference in New Issue
Block a user