diff options
author | Russ Cox <rsc@golang.org> | 2010-05-03 15:29:59 -0700 |
---|---|---|
committer | Russ Cox <rsc@golang.org> | 2010-05-03 15:29:59 -0700 |
commit | b5f54db35927cf1eee7f70a1a8d1d3a13e8578ab (patch) | |
tree | 57c00be0d01c38c781216b1f133a02875f017305 | |
parent | 371b77ad20a1a88820d6b75d184a36c1156f3003 (diff) | |
download | go-b5f54db35927cf1eee7f70a1a8d1d3a13e8578ab.tar.gz go-b5f54db35927cf1eee7f70a1a8d1d3a13e8578ab.zip |
gc: bug267
R=ken2
CC=golang-dev
https://golang.org/cl/1067042
-rw-r--r-- | src/cmd/gc/lex.c | 2 | ||||
-rw-r--r-- | test/fixedbugs/bug267.go (renamed from test/bugs/bug267.go) | 0 | ||||
-rw-r--r-- | test/golden.out | 4 |
3 files changed, 2 insertions, 4 deletions
diff --git a/src/cmd/gc/lex.c b/src/cmd/gc/lex.c index 7424f69671..48c200ccea 100644 --- a/src/cmd/gc/lex.c +++ b/src/cmd/gc/lex.c @@ -797,6 +797,7 @@ l0: * i said it was clumsy. */ case '(': + case '[': if(loophack || lstk != nil) { h = malloc(sizeof *h); h->v = loophack; @@ -806,6 +807,7 @@ l0: } goto lx; case ')': + case ']': if(lstk != nil) { h = lstk; loophack = h->v; diff --git a/test/bugs/bug267.go b/test/fixedbugs/bug267.go index 9646142f2a..9646142f2a 100644 --- a/test/bugs/bug267.go +++ b/test/fixedbugs/bug267.go diff --git a/test/golden.out b/test/golden.out index 3a9039fc5e..e0b6ad6242 100644 --- a/test/golden.out +++ b/test/golden.out @@ -185,7 +185,3 @@ panic: barCount != 1 panic PC=xxx BUG - -=========== bugs/bug267.go -bugs/bug267.go:14: syntax error: unexpected {, expecting : -BUG |