add test, fix bug: structs that differ in their

first field were not being handled correctly
because the visited map did not include the type.

R=r
OCL=31006
CL=31006
This commit is contained in:
Russ Cox 2009-07-01 16:45:09 -07:00
parent 25706fec19
commit a439f66228
3 changed files with 37 additions and 10 deletions

View file

@ -16,7 +16,7 @@ import (
type Addr unsafe.Pointer
func equalType(a, b Type) bool {
return a.String() == b.String()
return a.Kind() == b.Kind() && a.String() == b.String()
}
// Value is the generic interface to reflection values. Once its Kind is known,