From: Robert Griesemer Date: Fri, 21 Sep 2012 19:53:39 +0000 (+1000) Subject: [release-branch.go1] go/ast: Walk: do not walk comment list X-Git-Tag: go1.0.3~211 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=0352cdb054730cf94e51e35f581c058a1d9c8769;p=gostls13.git [release-branch.go1] go/ast: Walk: do not walk comment list ««« backport 5e3661048f2e go/ast: Walk: do not walk comment list A comment to that effect was introduced with rev d332f4b9cef5 but the respective code wasn't deleted. R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/6304086 »»» --- diff --git a/src/pkg/go/ast/walk.go b/src/pkg/go/ast/walk.go index 181cfd1491..66b1dc2499 100644 --- a/src/pkg/go/ast/walk.go +++ b/src/pkg/go/ast/walk.go @@ -344,9 +344,6 @@ func Walk(v Visitor, node Node) { } Walk(v, n.Name) walkDeclList(v, n.Decls) - for _, g := range n.Comments { - Walk(v, g) - } // don't walk n.Comments - they have been // visited already through the individual // nodes