]> Cypherpunks repositories - gostls13.git/commit
go/types: avoid redundant call to recordUse for anonymous fields
authorAlan Donovan <adonovan@google.com>
Fri, 4 Nov 2016 21:11:51 +0000 (17:11 -0400)
committerAlan Donovan <adonovan@google.com>
Fri, 4 Nov 2016 21:44:57 +0000 (21:44 +0000)
commit2c6949ec89817caecbb441422fe1d6729ee16462
treea291637e3752983186d86b15e407ec46ca1e08c3
parentcfd89164bb6af2d1a660b75ded8c0801372924e2
go/types: avoid redundant call to recordUse for anonymous fields

Anonymous fields are type expressions, and Checker.typexpr already
correctly records uses within them.  There's no need for a second
call, and the second call caused a bug when we implemented aliases.

Change-Id: I1bf2429cd4948d68b085e75dfb1bdc03ad8caffd
Reviewed-on: https://go-review.googlesource.com/32837
Reviewed-by: Robert Griesemer <gri@golang.org>
src/go/types/typexpr.go