]> Cypherpunks repositories - gostls13.git/commit
go/ast, go/parser: correct End() position for *ast.EmptyStmt
authorRobert Griesemer <gri@golang.org>
Tue, 24 Feb 2015 07:51:05 +0000 (23:51 -0800)
committerRobert Griesemer <gri@golang.org>
Tue, 24 Feb 2015 21:34:05 +0000 (21:34 +0000)
commit5ce9fde8b64a07a7cbfbe43c9451e2d1d536c972
tree235647f24d466e347f4f5b0b88cdd6589d74c447
parentc651fdc0cf2ba7986ce0a0a23b4dbb44b6ecdae3
go/ast, go/parser: correct End() position for *ast.EmptyStmt

- added a new field ast.EmptyStmt.Implicit to indicate explicit
  or implicit semicolon
- fix ast.EmptyStmt.End() accordingly
- adjusted parser and added test case

Fixes #9979.

Change-Id: I72b0983b3a0cabea085598e1bf6c8df629776b57
Reviewed-on: https://go-review.googlesource.com/5720
Reviewed-by: Russ Cox <rsc@golang.org>
doc/go1.5.txt
src/go/ast/ast.go
src/go/parser/parser.go
src/go/parser/parser_test.go