diff options
author | R?my Oudompheng <oudomphe@phare.normalesup.org> | 2013-06-23 18:39:07 +0200 |
---|---|---|
committer | R?my Oudompheng <oudomphe@phare.normalesup.org> | 2013-06-23 18:39:07 +0200 |
commit | 8eaf1205ec77716563d3f2df735da3252995d323 (patch) | |
tree | 2cfad54692543919322c8ecd09ba8a213d314176 /src | |
parent | 47c6f814448b41a2d1dd517c1f3ffdd1d95aae54 (diff) | |
download | go-8eaf1205ec77716563d3f2df735da3252995d323.tar.gz |
cmd/gc: fix pointer composite literals in exported if statements.
Fixes issue 4230 (again).
R=rsc, golang-dev, r
CC=golang-dev
https://codereview.appspot.com/10470043
Diffstat (limited to 'src')
-rw-r--r-- | src/cmd/gc/fmt.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cmd/gc/fmt.c b/src/cmd/gc/fmt.c index d541c967a..c7519c976 100644 --- a/src/cmd/gc/fmt.c +++ b/src/cmd/gc/fmt.c @@ -1222,7 +1222,7 @@ exprfmt(Fmt *f, Node *n, int prec) } if(fmtmode == FExp && ptrlit) // typecheck has overwritten OIND by OTYPE with pointer type. - return fmtprint(f, "&%T{ %,H }", n->right->type->type, n->list); + return fmtprint(f, "(&%T{ %,H })", n->right->type->type, n->list); return fmtprint(f, "(%N{ %,H })", n->right, n->list); case OPTRLIT: |