diff options
-rw-r--r-- | proptools/clone.go | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/proptools/clone.go b/proptools/clone.go index 1082762..fe4e115 100644 --- a/proptools/clone.go +++ b/proptools/clone.go @@ -35,8 +35,7 @@ func CopyProperties(dstValue, srcValue reflect.Value) { for i, field := range typeFields(typ) { if field.PkgPath != "" { - // The field is not exported so just skip it. - continue + panic(fmt.Errorf("can't copy a private field %q", field.Name)) } srcFieldValue := srcValue.Field(i) |