Fold Expr statements into Assign statements

This commit is contained in:
Nigel Tao committed 2018-12-27 17:36:08 +11:00
1 parent 796c8ccc30
commit c9e6ee6fb3
6 files changed
+34 -38

No files matched your search

+4
View File
@@ -240,6 +240,10 @@ func (h *resumabilityHelper) doAssign(r resumabilities, n *a.Assign, depth uint3
return err
}
if n.LHS() == nil {
return nil
}
// If the LHS is not a local variable (e.g. "this.foo[bar] = etc", or if
// the LHS is implicitly also on the RHS (e.g. for a += or *= operator),
// walk the LHS Expr.