-
Notifications
You must be signed in to change notification settings - Fork 102
std::shared_ptr and std::unique_ptr serialization support #33
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
Comments
Hi, Do you mean serialization of polymorphic types? |
Hi, |
Could you elaborate and give an example? I'm guessing you mean serialization via base pointer etc? |
I want to serialize base pointer that can point to base/derived object. when it get deserialize It should return the proper object. struct MyClass { |
I think the short answer is no. YAS de/serializes a set of data members that you specify per class. You have to make sure that whatever constructor you end up using after de-serialization will work correctly meaning will get you a proper object instance. As for runtime polymorphism the serialize/deserialize will work like any other function ptr would. |
Hi, do you have any plan to support std::shared_ptr and std::unique_ptr in the yas library?
The text was updated successfully, but these errors were encountered: