From 8d353c1949df16ca68bc05df1c096a4778332c70 Mon Sep 17 00:00:00 2001 From: Josh Bleecher Snyder Date: Fri, 30 Nov 2018 11:57:57 -0800 Subject: starlark: allow parenthesized expressions on LHS of augmented assignments (#29) Fixes #25 --- internal/compile/compile.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'internal') diff --git a/internal/compile/compile.go b/internal/compile/compile.go index 8da415b..479df5c 100644 --- a/internal/compile/compile.go +++ b/internal/compile/compile.go @@ -980,7 +980,7 @@ func (fcomp *fcomp) stmt(stmt syntax.Stmt) { var set func() // Evaluate "address" of x exactly once to avoid duplicate side-effects. - switch lhs := stmt.LHS.(type) { + switch lhs := unparen(stmt.LHS).(type) { case *syntax.Ident: // x = ... fcomp.lookup(lhs) -- cgit v1.2.3