diff options
Diffstat (limited to 'src/reflect/type.go')
-rw-r--r-- | src/reflect/type.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/reflect/type.go b/src/reflect/type.go index de6e05fb6d..891671017a 100644 --- a/src/reflect/type.go +++ b/src/reflect/type.go @@ -1848,6 +1848,7 @@ func ChanOf(dir ChanDir, t Type) Type { prototype := *(**chanType)(unsafe.Pointer(&ichan)) ch := new(chanType) *ch = *prototype + ch.tflag = 0 ch.dir = uintptr(dir) ch.str = resolveReflectName(newName(s, "", "", false)) ch.hash = fnv1(typ.hash, 'c', byte(dir)) @@ -1892,6 +1893,7 @@ func MapOf(key, elem Type) Type { mt := new(mapType) *mt = **(**mapType)(unsafe.Pointer(&imap)) mt.str = resolveReflectName(newName(s, "", "", false)) + mt.tflag = 0 mt.hash = fnv1(etyp.hash, 'm', byte(ktyp.hash>>24), byte(ktyp.hash>>16), byte(ktyp.hash>>8), byte(ktyp.hash)) mt.key = ktyp mt.elem = etyp |