func (ft fieldTree) matchPrefix(p cmp.Path) bool {
	for _, ps := range p {
		switch ps := ps.(type) {
		case cmp.StructField:
			ft = ft.sub[ps.Name()]
			if ft.ok {
				return true
			}
			if len(ft.sub) == 0 {
				return false
			}
		case cmp.Indirect:
		default:
			return false
		}
	}
	return false
}
func (ft fieldTree) matchPrefix(p cmp.Path) bool {
	for _, ps := range p {
		switch ps := ps.(type) {
		case cmp.StructField:
			ft = ft.sub[ps.Name()]
			if ft.ok {
				return true
			}
			if len(ft.sub) == 0 {
				return false
			}
		case cmp.Indirect:
		default:
			return false
		}
	}
	return false
}
func ( ft fieldTree ) matchPrefix ( p cmp . Path ) bool { for _ , ps := range p { switch ps := ps . ( type ) { case cmp . StructField : ft = ft . sub [ ps . Name ( ) ] if ft . ok { return true } if len ( ft . sub ) == 0 { return false } case cmp . Indirect : default : return false } } return false }
// matchPrefix reports whether any selector in the fieldTree matches
// the start of path p.
matchPrefix reports whether any selector in the fieldTree matches the start of path p .