Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated for compatibility with new TypeInfo-based Reflection API #13

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

leonluc-dev
Copy link

Updated for compatibility with new TypeInfo Reflection API, used in new
.NET environments like Windows Phone 8.1 , Apps for Windows Store and
their respective PCL profiles.

Updated for compatibility with new TypeInfo Reflection API, used in new
.NET environments like Windows Phone 8.1 and Apps for Windows Store and
their respective PCL profiles.
var clonedFieldValue = InternalCopy(originalFieldValue, visited);
propertyInfo.SetValue(cloneObject, clonedFieldValue);
}
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why implement CopyProperties? Properties are just setter and getter functions with underlying fields in a different syntax. Those underlying fields should already be copied in the CopyFields() method.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was actually a oversight on my part. I have corrected this in my latest commit.

CopyProperties method has been removed because underlying property
values are copied by the CopyField methods.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants