Trying to clone objects containing type PropertyInfo cause stack overflow.
Opened this issue · 2 comments
JoshWobbles commented
Seems to have issues with type PropertyInfo. Is there any way to mark properties of this type as excluded or allowed to reference?
jpreece6 commented
Just had the same issue. I solved this issue by creating a custom exclusion attribute, then mark fields that need to be excluded. A check for the exclusion attribute would be added to the CopyFields method.
MNF commented
It can be done as in pull request “Added ability to opt out of a deep copy for select properties, fields... #16”