From 1a9c46be99cf7d3c95a61bb78c83ebc92afc14a5 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Mon, 24 May 2010 16:55:23 -0700 Subject: gc: fix shift/reduce conflict in go.y export syntax Fixes issue 771. R=ken2 CC=golang-dev http://codereview.appspot.com/1267042 --- src/cmd/gc/subr.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/cmd/gc/subr.c') diff --git a/src/cmd/gc/subr.c b/src/cmd/gc/subr.c index b0192adf3..cf7b1865c 100644 --- a/src/cmd/gc/subr.c +++ b/src/cmd/gc/subr.c @@ -1295,8 +1295,12 @@ Tpretty(Fmt *fp, Type *t) fmtprint(fp, "... %T", t->type->type); } else fmtprint(fp, "%T", t->type); - if(t->note) - fmtprint(fp, " \"%Z\"", t->note); + if(t->note) { + fmtprint(fp, " "); + if(exporting) + fmtprint(fp, ":"); + fmtprint(fp, "\"%Z\"", t->note); + } return 0; case TFORW: -- cgit v1.2.3