-
Notifications
You must be signed in to change notification settings - Fork 212
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
Add clone to builder state types #379
Add clone to builder state types #379
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see why the states couldn't be Clone
, so yes, I think we can merge this (if CI is green of course 😆 ).
What's the status on this PR? |
Ah, thanks for pinging me! |
Thanks for the merge ! |
@matthiasbeyer Hi, what's the plan for publishing a new version including this PR? This has been a blocker to bump my lib. |
Hm. Can this be considered a backwards compatible fix? I am not sure. If it is, I could release a patchlevel version update. |
@matthiasbeyer This PR just adds Clone trait so the old code still works without any changes, I think. |
Submitted backport in #398 Will release 0.13.3 with this patch shortly. |
@matthiasbeyer Thank you so much 🙏 |
This PR is to add
Clone
impl to bothDefaultState
andAsyncState
. This allowsConfigBuilder
to be fully clonable. My goal is to make bevy plugin that insertsConfigBuilder
as resource so that developers can query them from systems and modify (e.g. configure additional source file etc.).I'm not 100% sure this is a right approach but it satisfied my use case for now. Let me know if there's other way to make it work.
Example
Without clone