commit | d67579759e1769c08148304b2d378ec0b05637d6 | [log] [tgz] |
---|---|---|
author | Ian Lance Taylor <iant@golang.org> | Wed Dec 23 16:32:30 2020 -0800 |
committer | Ian Lance Taylor <iant@golang.org> | Thu Dec 24 01:49:51 2020 +0000 |
tree | ca01ca6ae40042ef19b90c977ad090f2b5241781 | |
parent | 8d49adead59b8103f3bfeebd53ee508eda5ee94a [diff] |
compiler: parenthesize channel type strings if necessary Avoid the ambiguity between "chan <- (chan int)" and "chan (<- chan int)". This parenthesizes the same way as the gc compiler. Change-Id: I638c89058c48c486121ecb67a5f7285f099505c7 Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/279961 Trust: Ian Lance Taylor <iant@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com>