1
0
mirror of https://github.com/golang/go synced 2024-10-01 15:58:33 -06:00

cmd/6g: allow componentgen of slice inside struct

Change-Id: I847bf32bd0be913fad277c5e657f44df147eee14
Reviewed-on: https://go-review.googlesource.com/7729
Reviewed-by: Rob Pike <r@golang.org>
Reviewed-by: Minux Ma <minux@golang.org>
This commit is contained in:
Russ Cox 2015-03-09 15:42:49 -04:00
parent 08af4c3a79
commit b93fa309f2

View File

@ -1668,7 +1668,7 @@ func componentgen(nr *gc.Node, nl *gc.Node) bool {
fldcount := int64(0)
for t := nl.Type.Type; t != nil; t = t.Down {
if gc.Isfat(t.Type) {
if gc.Isfat(t.Type) && !gc.Isslice(t) {
goto no
}
if t.Etype != gc.TFIELD {