cmd/compile: add Fields field to Type

Switch TSTRUCT and TINTER to use Fields instead of Type, which wrings
out the remaining few direct uses of the latter.

Preparation for converting fields to use a separate "Field" type.

Passes toolstash/buildall.

Change-Id: I5a2ea7e159d0dde1be2c9afafc10a8f739d95743
Reviewed-on: https://go-review.googlesource.com/20675
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This commit is contained in:
Matthew Dempsky 2016-03-13 23:02:38 -07:00
parent 7971864267
commit 0d2e92c2ca
18 changed files with 89 additions and 83 deletions

View file

@ -592,13 +592,7 @@ func Isinter(t *Type) bool {
}
func isnilinter(t *Type) bool {
if !Isinter(t) {
return false
}
if t.Type != nil {
return false
}
return true
return Isinter(t) && countfield(t) == 0
}
func isideal(t *Type) bool {